/** * Lists all Menu record models. * @return mixed */ public function actionIndex() { $searchModel = new MenuSearch(); $dataProvider = $searchModel->search($this->_web->id); $web_id = $this->_web->id; return $this->render('index', compact('dataProvider', 'web_id')); }
/** * Lists all Menu models. * @return mixed */ public function actionIndex() { $searchModel = new MenuSearch(); $dataProvider = $searchModel->search(Yii::$app->request->queryParams); $dataProvider->pagination->pageSize = 10; return $this->render('index', ['searchModel' => $searchModel, 'dataProvider' => $dataProvider]); }