示例#1
0
 /**
  * Creates data provider instance with search query applied
  *
  * @param array $params
  *
  * @return ActiveDataProvider
  */
 public function search($params)
 {
     $query = Bancos::find();
     $dataProvider = new ActiveDataProvider(['query' => $query]);
     $query->joinWith(['idEmpresa']);
     //$this->load($params);
     if (!($this->load($params) && $this->validate())) {
         return $dataProvider;
     }
     $query->andFilterWhere(['id_banco' => $this->id_banco, 'numero_cuenta' => $this->numero_cuenta]);
     $query->andFilterWhere(['like', 'titular', $this->titular])->andFilterWhere(['like', 'banco', $this->banco])->andFilterWhere(['like', 'tipo_cuenta', $this->tipo_cuenta])->andFilterWhere(['LIKE', 'empresa.nombre', $this->id_empresa]);
     return $dataProvider;
 }
示例#2
0
 /**
  * Finds the Bancos model based on its primary key value.
  * If the model is not found, a 404 HTTP exception will be thrown.
  * @param integer $id
  * @return Bancos the loaded model
  * @throws NotFoundHttpException if the model cannot be found
  */
 protected function findModel($id)
 {
     if (($model = Bancos::findOne($id)) !== null) {
         return $model;
     } else {
         throw new NotFoundHttpException('The requested page does not exist.');
     }
 }
示例#3
0
?>
</p>
	<p>Valor en letras: <?php 
echo strtoupper($numeros->ValorEnLetras($model->valor, "PESOS"));
?>
 </p>
	<p>Por Concepto de: <?php 
echo strtoupper($model->detalle);
?>
</p>
</div>

<div class="cuerpo2">
  <?php 
use app\models\Bancos;
$bancos = new Bancos();
$cuentas = $bancos->find()->all();
?>
  <p>Puede Consignar en las siguentes cuentas:</p>
  <?php 
foreach ($cuentas as $row) {
    ?>
    <?php 
    if ($row->id_empresa == $model->idEmpresa->id_empresa) {
        ?>
    <span><?php 
        echo $row->banco;
        ?>
 </span><b>Nº <?php 
        echo $row->numero_cuenta;
        ?>