banki.test/views/list/edit.php

32 lines
812 B
PHP
Raw Normal View History

2024-08-20 07:53:49 +02:00
<?php
use yii\bootstrap5\ActiveForm;
use yii\bootstrap5\Html;
/** @var yii\web\View $this */
$this->title = $id ? "#$id parameter edit" : 'New parameter';
?>
<h1 class="display-4"><?= $this->title ?></h1>
<?php $form = ActiveForm::begin([
'options' => [
'enctype' => 'multipart/form-data',
]
]); ?>
<?= $form->field($model, 'title') ?>
<?= $form->field($model, 'type') ?>
<div class="card card-body mb-3 pb-0">
<p class="small">
Note: upload images only if type is 2. They will be ignored if type is 1
</p>
<?= $form->field($model, 'icon')->fileInput() ?>
<?= $form->field($model, 'iconGray')->fileInput() ?>
</div>
<?= Html::submitButton('Save', [ 'class' => 'btn btn-l btn-success w-100' ]) ?>
<?php ActiveForm::end(); ?>