Initial commit

This commit is contained in:
Chris Smith
2025-02-19 14:51:16 +01:00
commit d82a6cad96
198 changed files with 13819 additions and 0 deletions

View File

@@ -0,0 +1,41 @@
<?php
use yii\helpers\ArrayHelper;
use yii\helpers\Html;
use yii\bootstrap5\ActiveForm;
/** @var yii\web\View $this */
/** @var common\models\User $model */
/** @var array $salesAgents */
/** @var yii\widgets\ActiveForm $form */
?>
<div class="user-form">
<?php
$form = ActiveForm::begin(); ?>
<?= $form->field($model, 'email')->textInput() ?>
<?= $form->field($model, 'status')->dropDownList($model->getStatusName(true)) ?>
<?= $form->field($model, 'role')->dropDownList(
ArrayHelper::map(Yii::$app->authManager->getRoles(), 'name', 'name'),
['prompt' => '-- Select role --']
) ?>
<?= $form->field($model, 'sales_agent_id')->label(Yii::t('app', 'Sales Agent'))->dropDownList(
$salesAgents,
['prompt' => '-- Select Sales Agent --']
) ?>
<br/>
<div class="form-group">
<?= Html::submitButton(Yii::t('app', 'Save'), ['class' => 'btn btn-success']) ?>
</div>
<?php
ActiveForm::end(); ?>
</div>