芝麻web文件管理V1.00
编辑当前文件:/home2/sdektunc/airport-back/controllers/SeatclassController.php
'yii\data\ActiveDataFilter', 'searchModel'=>(new DynamicModel(['aircraft_id']))->addRule(['aircraft_id'],'integer') ]; return $actions; } public function serializeData($data){ $result=parent::serializeData($data); if($this->action->id=='view'){ $result=array_merge($result,$this->getCatalogs()); } return $result; } public function actionCatalogs(){ return $this->getCatalogs(); } private function getCatalogs(){ $airlines=Airline::find()->where(['active'=>1,'trash'=>0])->all(); //$aircrafts=Aircraft::find()->where(['active'=>1,'trash'=>0])->all(); return compact('airlines'); } } ?>