/** * Lists all Status models. * @return mixed */ public function actionIndex() { $searchModel = new StatusSearch(); $dataProvider = $searchModel->search(Yii::$app->request->queryParams); return $this->render('index', ['searchModel' => $searchModel, 'dataProvider' => $dataProvider]); }
<?php $form = ActiveForm::begin(); ?> <div class="row"> <div class="col-sm-6"> <div> <?php echo $form->field($model, 'title')->textInput(['maxlength' => true]); ?> </div> <div> <?php echo $form->field($model, 'status_id')->dropDownList(ArrayHelper::map(\app\modules\settings\models\StatusSearch::getAll(), 'id', 'title')); ?> </div> <div> <?php echo $form->field($model, 'priority_id')->dropDownList(ArrayHelper::map(\app\modules\settings\models\PrioritySearch::getAll(), 'id', 'title')); ?> </div> <div> <?php echo $form->field($model, 'type_id')->dropDownList(ArrayHelper::map(\app\modules\settings\models\TypeSearch::getAll(), 'id', 'title')); ?> </div>