Blame view

frontend/views/accounts/participant-edit.php 5.32 KB
2f324895   Yarik   test
1
2
3
  <?php
      use common\models\PortfolioUser;
      use common\modules\file\widgets\ImageUploader;
d8437b91   Yarik   test
4
      use mihaildev\ckeditor\CKEditor;
2f324895   Yarik   test
5
6
7
8
9
10
11
12
      use yii\helpers\Html;
      use yii\web\View;
      use yii\widgets\ActiveForm;
  
      /**
       * @var View          $this
       * @var PortfolioUser $model
       */
b9a54f61   Yarik   test
13
      $this->title = 'Редактирование участия в заказе';
2f324895   Yarik   test
14
15
16
      $this->params[ 'breadcrumbs' ][] = $this->title;
  ?>
  <div class="login-left-column-title"><?= $this->title ?></div>
c6206ab6   Виталий   git
17
  <div class="login-left-column-title-two style">Редактировать информацию о себе:</div>
2f324895   Yarik   test
18
      <?php
c6206ab6   Виталий   git
19
20
      if($model->status != 1) {
          ?>
1b2957f9   Виталий   git
21
          <div class="attention_bl style" role="alert">
c6206ab6   Виталий   git
22
23
24
25
              <strong>Внимание:</strong> данным действием Вы подтверждаете свое участие в проекте.
          </div>
          <?php
      }
2f324895   Yarik   test
26
      ?>
c6206ab6   Виталий   git
27
  
2f324895   Yarik   test
28
          <?php
c6206ab6   Виталий   git
29
          $form = ActiveForm::begin();
2f324895   Yarik   test
30
          ?>
c6206ab6   Виталий   git
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
          <div class="input-blocks-wrapper">
              <div class="input-blocks">
                  <?= $form->field($model, 'position')
                      ->textInput([ 'class' => 'custom-input-2' ]);
                  ?>
              </div>
          </div>
  
          <div class="input-blocks-wrapper">
              <div class="input-blocks">
                  <?=
                  $form->field($model, 'time')
                      ->textInput([
                          'class' => 'custom-input-2',
                          'type'  => 'number',
                          'min'   => 0,
                      ])
                  ?>
              </div>
          </div>
  
  
      <div class="login-left-column-title-two style">Добавить фотографию в личный альбом данного проекта:</div>
      <div class="input-blocks-wrapper full-blocks admin-editor-bl">
          <div class="input-blocks">
              <?php
              if($model->status == 1 && !empty( $model->gallery )) {
                  echo $form->field($model->portfolioGallery, 'caption')
                      ->widget(CKEditor::className(), [ 'editorOptions' => [ 'preset' => 'basic' ] ]);
                  echo Html::tag('div', ImageUploader::widget([
                      'model'   => $model->gallery,
                      'field'   => 'photo',
                      'size'    => [
                          [
                              'width'  => 152,
                              'height' => 108,
                          ],
d8437b91   Yarik   test
68
                      ],
c6206ab6   Виталий   git
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
                      'multi'   => true,
                      'gallery' => $model->gallery->photo,
                      'name'    => 'Загрузить фото галереи',
                  ]), [ 'class' => 'admin-gallery-photos-load-wr style' ]);
              } else {
                  echo Html::tag('p', 'Для добавления фотографий Вы должны подтвердить свое участие');
              }
              ?>
          </div>
      </div>
  
      <div class="admin-save-btn skills-save-btn admin-add-remove-wr style">
         <div class="admin-back-note">
             <?= Html::a('Вернуться', [ 'accounts/participant' ]); ?>
         </div>
  
          <?= Html::submitButton('Обновить'); ?>
2f324895   Yarik   test
86
          <?php
c6206ab6   Виталий   git
87
          $form->end();
2f324895   Yarik   test
88
          ?>
c6206ab6   Виталий   git
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
113
114
115
116
117
118
119
120
121
122
123
124
125
126
127
128
129
130
131
132
133
134
135
136
137
138
139
140
141
142
      </div>
  
  
  
  <!--<div>-->
  <!--    <p>Редактировать информацию о себе:</p>-->
  <!--    --><?php
  //        if($model->status != 1) {
  //            ?>
  <!--            <div class="alert alert-info" role="alert">-->
  <!--                <strong>Внимание:</strong> данным действием Вы подтверждаете свое участие в проекте.-->
  <!--            </div>-->
  <!--            --><?php
  //        }
  //    ?>
  <!--    <div>-->
  <!--        --><?php
  //            $form = ActiveForm::begin();
  //            echo $form->field($model, 'position')
  //                      ->textInput();
  //            echo $form->field($model, 'time')
  //                      ->input('number');
  //        ?>
  <!--    </div>-->
  <!--    <p>Добавить фотографию в личный альбом данного проекта:</p>-->
  <!--    --><?php
  //        if($model->status == 1 && !empty( $model->gallery )) {
  //            echo $form->field($model->portfolioGallery, 'caption')
  //                      ->widget(CKEditor::className(), [ 'editorOptions' => [ 'preset' => 'basic' ] ]);
  //            echo Html::tag('div', ImageUploader::widget([
  //                'model'   => $model->gallery,
  //                'field'   => 'photo',
  //                'size'    => [
  //                    [
  //                        'width'  => 152,
  //                        'height' => 108,
  //                    ],
  //                ],
  //                'multi'   => true,
  //                'gallery' => $model->gallery->photo,
  //                'name'    => 'Загрузить фото галереи',
  //            ]), [ 'class' => 'admin-gallery-photos-load-wr style' ]);
  //        } else {
  //            echo Html::tag('p', 'Для добавления фотографий Вы должны подтвердить свое участие');
  //        }
  //    ?>
  <!--    <p class="text-right">-->
  <!--        --><?php
  //            echo Html::a('Вернуться', [ 'accounts/participant' ]);
  //            echo Html::submitButton('Обновить');
  //            $form->end();
  //        ?>
  <!--    </p>-->
  <!--</div>-->