/** * @param string $route * @return mixed */ public function actionSelect($route = 'grom/news/post/view') { $searchModel = new PostSearch(); $dataProvider = $searchModel->search(Yii::$app->request->getQueryParams()); Yii::$app->grom->layout = 'modal'; return $this->render('select', ['dataProvider' => $dataProvider, 'searchModel' => $searchModel, 'route' => $route]); }
public function actionSelectPost() { $searchModel = new PostSearch(); $dataProvider = $searchModel->search(Yii::$app->request->getQueryParams()); $this->layout = 'modal'; return $this->render('select-post', ['dataProvider' => $dataProvider, 'searchModel' => $searchModel]); }