Blame view

frontend/views/road/create.php 720 Bytes
b41d5459   Yarik   first commit
1
2
3
4
5
  <?php
  
      /**
       * @var Road $road
       * @var array $road_types
b41d5459   Yarik   first commit
6
7
8
9
10
11
12
13
14
15
16
17
18
19
       */
  
      use common\models\Road;
      use yii\bootstrap\ActiveForm;
      use yii\bootstrap\Html;
  
      $this->title = 'My Yii Application';
  ?>
  <div class="site-index">
      <div class="col-xs-12">
          <?php
              $form = ActiveForm::begin([ 'id' => 'road-form' ]);
              echo $form->field($road, 'name')->textInput();
              echo $form->field($road, 'road_type_id')->dropDownList($road_types);
b41d5459   Yarik   first commit
20
21
22
23
24
25
26
              echo $form->field($road, 'index')->textInput();
              echo Html::submitButton('Добавить', ['class' => 'btn btn-success']);
              $form->end();
          ?>
      </div>
      <div class="clearfix"></div>
  </div>