/**
  * Manages all models.
  */
 public function actionAdmin()
 {
     $model = new Scheme('search');
     $model->unsetAttributes();
     // clear any default values
     if (isset($_GET['Scheme'])) {
         $model->attributes = $_GET['Scheme'];
     }
     $this->render('admin', array('model' => $model));
 }
Exemple #2
0
 /**
  * Manages all models.
  */
 public function actionAdmin()
 {
     if (Yii::app()->user->checkAccess($this->id . '.' . $this->action->id)) {
         $model = new Scheme('search');
         $model->unsetAttributes();
         // clear any default values
         if (isset($_GET['Scheme'])) {
             $model->attributes = $_GET['Scheme'];
         }
         $this->render('admin', array('model' => $model));
     } else {
         $this->accessDenied();
     }
 }