Commit be900c9426308b75e0b8920c28951e68854ba694

Authored by Alexey Boroda
1 parent 28855799

-Alter migration

console/migrations/m161227_163047_alter_columns.php 0 → 100644
  1 +<?php
  2 +
  3 +use yii\db\Migration;
  4 +
  5 +class m161227_163047_alter_columns extends Migration
  6 +{
  7 + public function up()
  8 + {
  9 + $this->alterColumn('intellectual_property', 'registration_date', $this->string(255));
  10 + $this->alterColumn('intellectual_property', 'creation_date', $this->string(255));
  11 + }
  12 +
  13 + public function down()
  14 + {
  15 + }
  16 +}
... ...
frontend/views/cabinet/sales.php
1 1 <?php
2 2 use frontend\models\IntellectualProperty;
  3 + use yii\helpers\Html;
3 4 use yii\web\View;
4 5 use yii\widgets\ActiveForm;
5 6 use yii\widgets\Pjax;
... ... @@ -135,7 +136,19 @@
135 136 </div>
136 137  
137 138 </div>
138   -
  139 +
  140 + <div class="btn-submit-blue">
  141 + <?php echo Html::button(
  142 + 'Добавить',
  143 + [
  144 + 'type' => 'button',
  145 + 'class' => 'add-role-button',
  146 + 'data-toggle' => 'modal',
  147 + 'data-target' => '#add-composition-modal',
  148 + ]
  149 + ) ?>
  150 + </div>
  151 +
139 152 <div class="style wrapp-tabs-table">
140 153 <div class="style table-wrapp-2">
141 154 <div class="hidden-tables-oiv active-tab-oiv">
... ... @@ -323,3 +336,70 @@
323 336 ?>
324 337 </div>
325 338 </div>
  339 +
  340 +<!-- Modal -->
  341 +<div class="modal fade" id="add-composition-modal" tabindex="-1" role="dialog" aria-labelledby="myModalLabel">
  342 + <div class="modal-dialog" role="document">
  343 + <div class="modal-content">
  344 + <div class="modal-header">
  345 + <button type="button" class="close" data-dismiss="modal" aria-label="Close">
  346 + <span aria-hidden="true">&times;</span></button>
  347 + <h4 class="modal-title" id="myModalLabel">Додати твір</h4>
  348 + </div>
  349 + <?php
  350 + $form = ActiveForm::begin(
  351 + [
  352 + 'action' => 'add-int-prop',
  353 + 'id' => 'add-int-prop-form',
  354 + ]
  355 + );
  356 + $addIntProp = new IntellectualProperty();
  357 + ?>
  358 + <div class="modal-body forms-cabinet forms-2">
  359 +
  360 +
  361 +
  362 + <?php
  363 + echo $form->field($addIntProp, 'title');
  364 + ?>
  365 +
  366 + <?php
  367 + echo $form->field($addIntProp, 'registration_date')->textInput([
  368 + 'class' => '_datepicker form-control',
  369 + ]);
  370 + ?>
  371 +
  372 + <?php
  373 + echo $form->field($addIntProp, 'genre');
  374 + ?>
  375 +
  376 + <?php
  377 + echo $form->field($addIntProp, 'author_role');
  378 + ?>
  379 +
  380 + <?php
  381 + echo $form->field($addIntProp, 'percent');
  382 + ?>
  383 +
  384 + <?php
  385 + echo $form->field($addIntProp, 'calculated');
  386 + ?>
  387 +
  388 + <?php
  389 + echo $form->field($addIntProp, 'play_count');
  390 + ?>
  391 +
  392 + </div>
  393 + <div class="modal-footer btn-submit-blue">
  394 + <?php
  395 + echo Html::submitButton(
  396 + 'OK'
  397 + );
  398 + ?>
  399 + </div>
  400 + <?php
  401 + $form::end();
  402 + ?>
  403 + </div>
  404 + </div>
  405 +</div>
326 406 \ No newline at end of file
... ...
frontend/web/css/cabinet-style.css
... ... @@ -767,6 +767,11 @@ ul.list-cab li.active-li ul li.active-li-drop span.act_bg {
767 767 float: left;
768 768 margin-bottom: 20px;
769 769 }
  770 +.cab_content_list-dropdown .add-role-button {
  771 + float: left;
  772 + margin-left: 20px;
  773 + margin-top: 30px;
  774 +}
770 775  
771 776 @media (max-width: 1566px) {
772 777 /*.content-forms {padding-right: 20px;}*/
... ...