/** * Lists all ProductCategory models. * @return mixed */ public function actionIndex() { $searchModel = new ProductCategorySearch(); $dataProvider = $searchModel->search(Yii::$app->request->queryParams); Url::remember(); return $this->render('index', ['searchModel' => $searchModel, 'dataProvider' => $dataProvider]); }
public function actionIndex() { $filterModel = new ProductCategorySearch(); $dataProvider = $filterModel->search(Yii::$app->request->queryParams); return $this->render('index', compact('dataProvider', 'filterModel')); }