Blame view

views/manage/update.php 601 Bytes
a2cde075   Yarik   first commit
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
  <?php
      use artweb\artbox\comment\models\CommentModel;
      use yii\helpers\Html;
      use yii\widgets\ActiveForm;
      
      /**
       * @var CommentModel $model
       */
      $statuses = [
          $model::STATUS_ACTIVE  => 'Активный',
          $model::STATUS_HIDDEN  => 'Скрытый',
          $model::STATUS_DELETED => 'Удаленный',
      ];
      $form = ActiveForm::begin();
      echo $form->field($model, 'text')
                ->textarea();
      echo $form->field($model, 'status')
                ->dropDownList($statuses);
      echo Html::submitButton('Обновить');
      $form->end();