/** * 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]); }
public function actionList() { $searchModel = new TourSearch(); $dataProvider = $searchModel->search(Yii::$app->request->queryParams); return $this->render('list', ['searchModel' => $searchModel, 'dataProvider' => $dataProvider]); }