예제 #1
0
 /**
  * Lists all Tour models.
  * @return mixed
  */
 public function actionIndex()
 {
     $searchModel = new TourSearch();
     $dataProvider = $searchModel->search(Yii::$app->request->queryParams);
     /*if(Yii::$app->request->isAjax){
           return $this->render('index', [
               'searchModel' => $searchModel,
               'dataProvider' => $dataProvider,
           ]);
       }*/
     return $this->render('index', ['searchModel' => $searchModel, 'dataProvider' => $dataProvider]);
 }
예제 #2
0
 public function actionList()
 {
     $searchModel = new TourSearch();
     $dataProvider = $searchModel->search(Yii::$app->request->queryParams);
     return $this->render('list', ['searchModel' => $searchModel, 'dataProvider' => $dataProvider]);
 }