Ejemplo n.º 1
0
 /**
  * Manages all models.
  */
 public function actionIndex()
 {
     try {
         $model = new StaticBlock('search');
         $model->unsetAttributes();
         // clear any default values
         if (isset($_GET['StaticBlock'])) {
             $model->attributes = $_GET['StaticBlock'];
         }
         $this->render('index', array('model' => $model, 'actions' => $this->listActionsCanAccess));
     } catch (Exception $e) {
         Yii::log("Exception " . print_r($e, true), 'error');
         throw new CHttpException("Exception " . print_r($e, true));
     }
 }