Blame view

frontend/views/accounts/_job_form.php 4.59 KB
eb7e82fb   Administrator   29.02.16
1
  <?php

4b85f536   Yarik   test
2
3
4
5
      /**

       * @var integer $index

       */

      use common\models\Job;

c20d5820   Yarik   test
6
      use mihaildev\ckeditor\CKEditor;

4b85f536   Yarik   test
7
8
9
      use yii\helpers\Html;

      use yii\jui\DatePicker;

      use yii\widgets\ActiveForm;

eb7e82fb   Administrator   29.02.16
10
  

4b85f536   Yarik   test
11
12
13
14
15
      $model = new Job([

          'user_id' => \Yii::$app->user->getId(),

          'current' => 0,

      ]);

      $form = ActiveForm::begin();

eb7e82fb   Administrator   29.02.16
16
  ?>

4b85f536   Yarik   test
17
18
  <div class='ajax-loaded'>

      <div class='prev_job_inputs'>

eb7e82fb   Administrator   29.02.16
19
20
          <div class="input-blocks-wrapper">

              <div class="input-blocks">

4b85f536   Yarik   test
21
22
23
                  <?= $form->field($model, '[' . $index . ']name')

                           ->label('Название')

                           ->textInput([ 'class' => 'custom-input-2' ]); ?>

eb7e82fb   Administrator   29.02.16
24
25
              </div>

          </div>

803325d5   Виталий   git
26
          <div class="input-blocks-wrapper hint-link">

eb7e82fb   Administrator   29.02.16
27
              <div class="input-blocks">

4b85f536   Yarik   test
28
29
30
31
                  <?= $form->field($model, '[' . $index . ']link')

                           ->label('Ссылка на компанию на сайте МФП')

                           ->hint('Пример: ' . $_SERVER[ 'HTTP_HOST' ] . '/company/common/1')

                           ->textInput([ 'class' => 'custom-input-2' ]); ?>

eb7e82fb   Administrator   29.02.16
32
33
34
35
              </div>

          </div>

          <div class="input-blocks-wrapper">

              <div class="input-blocks">

4b85f536   Yarik   test
36
37
38
39
40
41
42
43
44
45
46
47
                  <?= $form->field($model, '[' . $index . ']date_start')

                           ->label('Дата начала работы')

                           ->widget(DatePicker::className(), [

                               'options'       => [ 'class' => 'custom-input-2' ],

                               'language'      => 'ru',

                               'dateFormat'    => 'dd-MM-yyyy',

                               'clientOptions' => [

                                   'changeYear'  => true,

                                   'yearRange'   => 'c-20:c',

                                   'changeMonth' => true,

                               ],

                           ]); ?>

eb7e82fb   Administrator   29.02.16
48
49
50
51
52
              </div>

          </div>

  

          <div class="input-blocks-wrapper">

              <div class="input-blocks">

4b85f536   Yarik   test
53
54
55
56
57
58
59
60
61
62
63
64
                  <?= $form->field($model, '[' . $index . ']date_end')

                           ->label('Дата окончания работы')

                           ->widget(DatePicker::className(), [

                               'options'       => [ 'class' => 'custom-input-2' ],

                               'language'      => 'ru',

                               'dateFormat'    => 'dd-MM-yyyy',

                               'clientOptions' => [

                                   'changeYear'  => true,

                                   'yearRange'   => 'c-20:c',

                                   'changeMonth' => true,

                               ],

                           ]); ?>

eb7e82fb   Administrator   29.02.16
65
66
67
68
69
              </div>

          </div>

  

          <div class="input-blocks-wrapper">

              <div class="input-blocks">

4b85f536   Yarik   test
70
71
72
                  <?= $form->field($model, '[' . $index . ']position')

                           ->label('Должность')

                           ->textInput([ 'class' => 'custom-input-2' ]); ?>

eb7e82fb   Administrator   29.02.16
73
74
75
              </div>

          </div>

  

c20d5820   Yarik   test
76
77
78
79
80
81
82
83
          <div class="input-blocks-wrapper">

              <div class="input-blocks">

                  <?= $form->field($model, '[' . $index . ']achievement')

                           ->label('Достижения')

                           ->widget(CKEditor::className(), [ 'editorOptions' => [ 'preset' => 'basic' ] ]); ?>

              </div>

          </div>

  

eb7e82fb   Administrator   29.02.16
84
85
          <div class="input-blocks-wrapper admin-quantity-project">

              <div class="input-blocks">

4b85f536   Yarik   test
86
87
88
89
90
91
                  <?= $form->field($model, '[' . $index . ']total_count')

                           ->label('Количество проектов, в которых принимали участие')

                           ->textInput([

                               'class' => 'custom-input-2 custom-input-2-date',

                               'type'  => 'number',

                           ]); ?>

eb7e82fb   Administrator   29.02.16
92
93
  

                  <div class="fix-quantity-project">

5d627502   Yarik   test
94
                      <?= $form->field($model, '[' . $index . ']complete_count', [ 'enableClientValidation' => false ])

4b85f536   Yarik   test
95
96
                               ->label('из них реализовано')

                               ->textInput([

5d627502   Yarik   test
97
                                   'class' => 'custom-input-2 custom-input-2-date no-client-validation',

4b85f536   Yarik   test
98
99
                                   'type'  => 'number',

                               ]); ?>

eb7e82fb   Administrator   29.02.16
100
101
102
103
                  </div>

              </div>

          </div>

  

4b85f536   Yarik   test
104
105
106
107
          <?= Html::button('', [ 'class' => 'remove_job_button' ]); ?>

      </div>

  </div>

  <?php $form->end(); ?>