/** * Lists all DeviceInfo models. * @return mixed */ public function actionIndex() { // $ips = DeviceIpfilter::getIdsByType([DeviceIpfilter::TYPE_WLAN,DeviceIpfilter::TYPE_POLYMER]); $searchModel = new DeviceInfoSearch(); $dataProvider = $searchModel->search(Yii::$app->request->queryParams); return $this->render('index', ['searchModel' => $searchModel, 'dataProvider' => $dataProvider]); }
/** * Lists all DeviceInfo models. * @return mixed */ public function actionIndex() { $ips = DeviceInfo::find()->where(["categoryId" => "1001"])->select("ip")->column(); $ips = array_merge($ips, DeviceIpfilter::getIdsByType(DeviceIpfilter::TYPE_POLYMER)); $searchModel = new DeviceInfoSearch(); $dataProvider = $searchModel->search(Yii::$app->request->queryParams, $ips); return $this->render('index', ['searchModel' => $searchModel, 'dataProvider' => $dataProvider]); }