user card level

This commit is contained in:
andrey
2021-06-30 17:30:53 +03:00
parent 8c9b5f04d4
commit 74ada385f5
5 changed files with 70 additions and 3 deletions

View File

@ -129,6 +129,14 @@ use yii\widgets\ActiveForm;
</div>
</div>
<div class="row">
<div class="col-xs-6">
<?= $form->field($model, 'level')->dropDownList(
\common\models\UserCard::getLevelList(),
['prompt' => '...']
) ?>
</div>
</div>
<div class="row">

View File

@ -35,6 +35,12 @@ $this->params['breadcrumbs'][] = $this->title;
return Html::tag('img', null, ['src' => $model->photo, 'width' => '100px']);
}
],
[
'attribute' => 'level',
'value' => function($model){
return \common\models\UserCard::getLevelLabel($model->level);
}
],
[
'attribute' => 'resume',
'format' => 'raw',