add to form firlds

This commit is contained in:
king199025 2018-10-11 17:45:35 +03:00
parent 43557838ac
commit c9db4cd49b
5 changed files with 24 additions and 0 deletions

View File

@ -16,6 +16,7 @@ class UserCard extends \common\models\UserCard
[ [
'card_id' => \Yii::$app->request->get('id'), 'card_id' => \Yii::$app->request->get('id'),
'project_id' => null, 'project_id' => null,
'company_id' => null,
]) ])
->all(); ->all();
$array = []; $array = [];

View File

@ -100,6 +100,15 @@ use yii\widgets\ActiveForm;
) ?> ) ?>
</div> </div>
</div> </div>
<div class="row">
<div class="col-xs-6">
<?= $form->field($model, 'salary')->textInput(['maxlength' => true]) ?>
</div>
</div>
<div class="row"> <div class="row">
<div class="col-xs-12"> <div class="col-xs-12">
<?= $form->field($model, 'fields')->widget(MultipleInput::class, [ <?= $form->field($model, 'fields')->widget(MultipleInput::class, [

View File

@ -48,6 +48,7 @@ $this->params['breadcrumbs'][] = $this->title;
'label' => 'status', 'label' => 'status',
'value' => $model->status0->name, 'value' => $model->status0->name,
], ],
'salary',
'created_at', 'created_at',
'updated_at', 'updated_at',
], ],

View File

@ -21,6 +21,7 @@ class Project extends \common\models\Project
[ [
'project_id' => \Yii::$app->request->get('id'), 'project_id' => \Yii::$app->request->get('id'),
'card_id' => null, 'card_id' => null,
'company_id' => null,
]) ])
->all(); ->all();
$array = []; $array = [];

View File

@ -18,6 +18,18 @@ use yii\widgets\ActiveForm;
<?= $form->field($model, 'description')->textarea(['rows' => 6]) ?> <?= $form->field($model, 'description')->textarea(['rows' => 6]) ?>
<?= $form->field($model, 'budget')->textInput(['maxlength' => true]) ?>
<?= $form->field($model, 'company_id')->widget(Select2::class,
[
'data' => \yii\helpers\ArrayHelper::map(\common\models\Company::find()->all(),'id', 'name'),
'options' => ['placeholder' => '...','class' => 'form-control'],
'pluginOptions' => [
'allowClear' => true
],
]
); ?>
<div class="row"> <div class="row">
<div class="col-xs-12"> <div class="col-xs-12">
<?= $form->field($model, 'fields')->widget(MultipleInput::class, [ <?= $form->field($model, 'fields')->widget(MultipleInput::class, [