<?php echo $form->field($user, 'email')->textInput(['maxlength' => 255]); echo $form->field($user, 'role')->dropDownList(\yii\helpers\ArrayHelper::map(\lenarx\rbac\models\Rbac::find()->all(), 'name', 'title'), ['prompt' => 'выберите группу']); echo $form->field($user, 'username')->textInput(['maxlength' => 255]); echo $form->field($user, 'password')->passwordInput();
public function actionIndex() { $dataProvider = new ActiveDataProvider(['query' => Rbac::find()]); return $this->render('index', ['dataProvider' => $dataProvider]); }