Exemplo n.º 1
0
 /**
  * Lists all Service models.
  * @return mixed
  */
 public function actionIndex()
 {
     $searchModel = new ServiceSearch();
     $dataProvider = $searchModel->search(Yii::$app->request->queryParams);
     $cat = Category::find()->orderBy('name_pt')->asArray()->all();
     return $this->render('index', ['searchModel' => $searchModel, 'dataProvider' => $dataProvider, 'cat' => $cat]);
 }
Exemplo n.º 2
0
 /**
  * Displays the index (home) page.
  * Use it in case your home page contains static content.
  *
  * @return string
  */
 public function actionIndex()
 {
     $searchModel = new ServiceSearch();
     $searchModel->promo = true;
     $dataProvider = $searchModel->search(Yii::$app->request->queryParams);
     return $this->render('tempindex', ['cat' => Category::find()->orderBy('name_pt')->all(), 'serv' => Service::find()->orderBy('title_pt')->all(), 'modelImg' => Campaign::find()->one(), 'dataProvider' => $dataProvider]);
 }
Exemplo n.º 3
0
 /**
  * Lists all ServiceRecord models.
  * @return mixed
  */
 public function actionIndex()
 {
     $searchModel = new ServiceSearch();
     $dataProvider = $searchModel->search(Yii::$app->request->queryParams);
     return $this->render('index', ['searchModel' => $searchModel, 'dataProvider' => $dataProvider]);
 }