Ejemplo n.º 1
0
 /**
  * Manages all models.
  */
 public function actionAdmin()
 {
     $model = new Evento('search');
     $model->unsetAttributes();
     // clear any default values
     if (isset($_GET['Evento'])) {
         $model->attributes = $_GET['Evento'];
     }
     $this->render('admin', array('model' => $model));
 }
Ejemplo n.º 2
0
 /**
  * Manages all models.
  */
 public function actionAdmin()
 {
     //Yii::app()->clientScript->registerScript('uniqueid', 'alert("ok");alert("ok2");');
     $model = new Evento('search');
     $model_paciente = Paciente::model()->findAll();
     $autoCompletePaciente = Base::toAutoCompleteFormat($model_paciente);
     $model->unsetAttributes();
     // clear any default values
     if (isset($_GET['Evento'])) {
         $model->attributes = $_GET['Evento'];
     }
     $this->render('admin', array('model' => $model, 'calendarJSON' => $this->cargarEventos(), 'model_paciente' => $model_paciente, 'autoCompletePaciente' => $autoCompletePaciente));
 }