예제 #1
0
 /**
  * This is the default 'index' action that is invoked
  * when an action is not explicitly requested by users.
  */
 public function actionIndex()
 {
     $model = new Reserva('search');
     $model->unsetAttributes();
     // clear any default values
     if (isset($_GET['Reserva'])) {
         $model->attributes = $_GET['Reserva'];
         //            var_dump($model);
         //            die();
     }
     $this->render('index', array('model' => $model));
     // renders the view file 'protected/views/site/index.php'
     // using the default layout 'protected/views/layouts/main.php'
     //		$this->render('index');
 }
예제 #2
0
 /**
  * Manages all models.
  */
 public function actionAdmin()
 {
     $model = new Reserva('search');
     $model->unsetAttributes();
     // clear any default values
     if (isset($_GET['Reserva'])) {
         $model->attributes = $_GET['Reserva'];
     }
     $this->render('admin', array('model' => $model));
 }