Пример #1
0
 /**
  *  Check application activation
  * @return boolean
  */
 public function checkActive()
 {
     $searchModel = new AppsSearch();
     if ($searchModel->find()->where(['name' => 'recipes', 'active' => true])->one()) {
         return true;
     }
 }
Пример #2
0
 public function getAppsList()
 {
     $searchModel = new AppsSearch();
     $appsList = $searchModel->find()->where(['active' => true])->all();
     return $appsList;
 }
 public function actionIndex()
 {
     $searchModel = new AppsSearch();
     $applications = $searchModel->find()->where(['active' => true])->all();
     return $this->render('index', ['applications' => $applications]);
 }
Пример #4
0
 /**
  * Lists all Apps models.
  * @return mixed
  */
 public function actionIndex()
 {
     $searchModel = new AppsSearch();
     $dataProvider = $searchModel->search(Yii::$app->request->queryParams);
     return $this->render('index', ['searchModel' => $searchModel, 'dataProvider' => $dataProvider]);
 }