diff --git a/backend/web/js/option.js b/backend/web/js/option.js index 48a0b19..1894753 100755 --- a/backend/web/js/option.js +++ b/backend/web/js/option.js @@ -151,4 +151,73 @@ $(function() { $(document).on('change', 'input[name="User[type]"]', function() { accountRedraw(); }); -}); \ No newline at end of file +}); +$(document).ready(function(){ + specializationTags() + function specializationTags(){ + addSpecializationTagsLoad() + removeSpecializationTags() + newAddSpecializationTags() + checkSpecialization() + + function addSpecializationTagsLoad(){ + var specTags = $('.admin-page .third-ul-menu input:checked') + for (var spI=0;spI'+newSpecTagsTxt+'') + } + } + + function removeSpecializationTags(){ + $('body').on('click', '.admin-page .admin-specialization-selected ul li', function(){ + var removeSpecTagsId = $(this).attr('data-spec-id') + $('.admin-page .third-ul-menu #'+removeSpecTagsId).attr('checked', false) + $(this).remove() + + if(($('.admin-page .admin-specialization-selected ul li').size())<1){ + $('.input-blocks-wrapper.admin-menu-list .admn-menu-err').addClass('has-error') + } else { + $('.input-blocks-wrapper.admin-menu-list .admn-menu-err').addClass('has-error').removeClass('has-error') + } + }) + } + + function newAddSpecializationTags(){ + $('.admin-page .third-ul-menu input').change(function(){ + var thisSpecTagsId = $(this).attr('id') + var thisSpecTagsTxt = $(this).parents('a').text() + if($(this).prop("checked")){ + $('.admin-page .admin-specialization-selected ul').append('
  • '+thisSpecTagsTxt+'
  • ') + } else { + $('.admin-page .admin-specialization-selected ul li[data-spec-id="'+thisSpecTagsId+'"]').remove() + + } + + if( ($('.admin-page .admin-specialization-selected ul li').length)>0 ){ + $('.input-blocks-wrapper.admin-menu-list .admn-menu-err').addClass('has-error').removeClass('has-error') + } else { + $('.input-blocks-wrapper.admin-menu-list .admn-menu-err').addClass('has-error') + } + }) + } + + function checkSpecialization(){ + if($('.input-blocks-wrapper').hasClass('admin-menu-list')){ + $('body').on('click', '.admin-page .admin-save-btn button', function(e){ + if( ($('.admin-page .admin-specialization-selected ul li').length)>0 ){ + $('.input-blocks-wrapper.admin-menu-list .admn-menu-err').removeClass('has-error') + } else { + var errorOffsetSpecial = $('.input-blocks-wrapper.admin-menu-list').offset().top + e.preventDefault() + $('body,html').animate({scrollTop:errorOffsetSpecial-50}, 400) + $('.input-blocks-wrapper.admin-menu-list .admn-menu-err').addClass('has-error') + } + }) + } + } + } + $('.admin-page .admin-menu-list .content-menu-first a').addClass('no-click') + $('.admin-page .admin-menu-list .content-menu-first a.remove-link, .third-ul-menu a').removeClass('no-click') + $('.admin-page .admin-menu-list .content-menu-first a.no-click').click(function(e){e.preventDefault()}) +}) diff --git a/frontend/views/accounts/_portfolio_form.php b/frontend/views/accounts/_portfolio_form.php index 58ade4f..6789151 100644 --- a/frontend/views/accounts/_portfolio_form.php +++ b/frontend/views/accounts/_portfolio_form.php @@ -46,46 +46,58 @@
    - +
    + +
    +
    + + + +
    +
    Необходимо выбрать хотя бы одну «специализацию».
    +
    +
    Фото главное
    diff --git a/frontend/views/accounts/_projects_form.php b/frontend/views/accounts/_projects_form.php index 2caec43..b553025 100644 --- a/frontend/views/accounts/_projects_form.php +++ b/frontend/views/accounts/_projects_form.php @@ -47,47 +47,59 @@ ->dropDownList($projects, [ 'prompt' => 'Родительский проект' ]) ?>
    +
    - +
    + +
    +
    + +
    +
    Необходимо выбрать хотя бы одну «специализацию».
    +
    +
    +
    Адрес проекта:
    diff --git a/frontend/views/accounts/_vacancy_form.php b/frontend/views/accounts/_vacancy_form.php index 65b99f6..645a9d9 100644 --- a/frontend/views/accounts/_vacancy_form.php +++ b/frontend/views/accounts/_vacancy_form.php @@ -103,54 +103,58 @@ -
    -
      +
        -
      -
      - -
      +
      field($vacancy, 'employmentInput') ->checkboxList($employment, @@ -219,41 +223,5 @@ $('.input-blocks.admin-currency-second select').change(function(){ $(this).blur() }) - - specializationTags() - function specializationTags(){ - addSpecializationTags() - removeSpecializationTags() - newAddSpecializationTags() - - function addSpecializationTags(){ - var specTags = $('.admin-page .third-ul-menu input:checked') - for (var spI=0;spI'+newSpecTagsTxt+'') - } - } - - function removeSpecializationTags(){ - $('body').on('click', '.admin-page .admin-specialization-selected ul li', function(){ - var removeSpecTagsId = $(this).attr('data-spec-id') - $('.admin-page .third-ul-menu #'+removeSpecTagsId).attr('checked', false) - $(this).remove() - }) - } - - function newAddSpecializationTags(){ - $('.admin-page .third-ul-menu input').change(function(){ - var thisSpecTagsId = $(this).attr('id') - var thisSpecTagsTxt = $(this).parents('a').text() - if($(this).prop("checked")){ - $('.admin-page .admin-specialization-selected ul').append('
    • '+thisSpecTagsTxt+'
    • ') - } else { - $('.admin-page .admin-specialization-selected ul li[data-spec-id="'+thisSpecTagsId+'"]').remove() - } - }) - } - } }) \ No newline at end of file diff --git a/frontend/views/accounts/service.php b/frontend/views/accounts/service.php index b6abc2c..b09b2cf 100755 --- a/frontend/views/accounts/service.php +++ b/frontend/views/accounts/service.php @@ -52,42 +52,58 @@
      - +
      +
      Необходимо выбрать хотя бы одну «специализацию».
      +
      + +
        +
        field($user_info, 'geographies') diff --git a/frontend/views/accounts/vacancy.php b/frontend/views/accounts/vacancy.php index 4e819d7..f839a84 100644 --- a/frontend/views/accounts/vacancy.php +++ b/frontend/views/accounts/vacancy.php @@ -17,71 +17,74 @@
        'btn btn-success' ]) ?>
        - ['class'=>'style admin-all-pages-wr'], - 'dataProvider' => $dataProvider, - 'filterModel' => $searchModel, - 'columns' => [ - [ - 'attribute' => 'vacancy_id', - 'label' => 'ID', - ], - 'name', - [ - 'attribute' => 'date_add', - 'filter' => "
        +
        + ['class'=>'style admin-all-pages-wr'], + 'dataProvider' => $dataProvider, + 'filterModel' => $searchModel, + 'columns' => [ + [ + 'attribute' => 'vacancy_id', + 'label' => 'ID', + ], + 'name', + [ + 'attribute' => 'date_add', + 'filter' => "
        ". - DatePicker::widget([ - 'model' => $searchModel, - 'attribute' => 'date_add_from', - 'language' => 'ru', - 'dateFormat' => 'yyyy-MM-dd', - 'clientOptions' => [ - 'changeYear' => true, - 'changeMonth' => true, - ], - ]). - " + DatePicker::widget([ + 'model' => $searchModel, + 'attribute' => 'date_add_from', + 'language' => 'ru', + 'dateFormat' => 'yyyy-MM-dd', + 'clientOptions' => [ + 'changeYear' => true, + 'changeMonth' => true, + ], + ]). + " ". - DatePicker::widget([ - 'model' => $searchModel, - 'attribute' => 'date_add_to', - 'language' => 'ru', - 'dateFormat' => 'yyyy-MM-dd', - 'clientOptions' => [ - 'changeYear' => true, - 'changeMonth' => true, - ], - ]) - ." + DatePicker::widget([ + 'model' => $searchModel, + 'attribute' => 'date_add_to', + 'language' => 'ru', + 'dateFormat' => 'yyyy-MM-dd', + 'clientOptions' => [ + 'changeYear' => true, + 'changeMonth' => true, + ], + ]) + ."
        ", - 'format' => 'html', - ], - 'view_count', - [ - 'class' => ActionColumn::className(), - 'buttons' => [ - 'update' => function($url, $model, $key) { - return Html::a('', - ['vacancy-update', 'id' => $model->vacancy_id - ],[ - 'title' => 'Редактировать', - ]); - }, - 'delete' => function($url, $model, $key) { - return Html::a('', ['vacancy-delete', 'id' => $model->vacancy_id], [ - 'title' => 'Удалить', - 'aria-label' => 'Удалить', - 'data-confirm' => 'Вы уверены, что хотите удалить этот элемент?', - 'data-method' => 'post', - 'data-pjax' => '0', - ]); - }, + 'format' => 'html', ], - 'template' => '{update} {delete}' + 'view_count', + [ + 'class' => ActionColumn::className(), + 'buttons' => [ + 'update' => function($url, $model, $key) { + return Html::a('', + ['vacancy-update', 'id' => $model->vacancy_id + ],[ + 'title' => 'Редактировать', + ]); + }, + 'delete' => function($url, $model, $key) { + return Html::a('', ['vacancy-delete', 'id' => $model->vacancy_id], [ + 'title' => 'Удалить', + 'aria-label' => 'Удалить', + 'data-confirm' => 'Вы уверены, что хотите удалить этот элемент?', + 'data-method' => 'post', + 'data-pjax' => '0', + ]); + }, + ], + 'template' => '{update} {delete}' + ] ] - ] -]); ?> + ]); ?> +
        + diff --git a/frontend/web/css/style.css b/frontend/web/css/style.css index 32c0ba1..08c7529 100755 --- a/frontend/web/css/style.css +++ b/frontend/web/css/style.css @@ -5936,12 +5936,14 @@ a {color: #0072bc} margin-left: 0; } .admin-who-check-payment .custom-check + label:hover {border-bottom: 1px solid #333333} +.admin-who-check-payment {margin-top: 6px} .admin-service-wr .input-blocks-wrapper { margin-top: 24px; } .admin-vacancy-check .admin-who-check-payment { margin-top: 10px; } +.admin-vacancy-check-fx-marg .admin-who-check-payment {margin-top: 6px} .admin-vacancy-check .admin-who-check-payment:first-child {margin-top: 6px} .admin-hint-vacancy-contact { position: absolute; @@ -6242,6 +6244,7 @@ input[disabled], select[disabled] { .admin-table-gallery .input-group.input-group-xs input { width: 131px; } +.admin-table-vacancy table tr td:first-child{max-width: 80px} .admin-table-gallery .input-group.input-group-xs.input-daterange { width: 293px; } @@ -6344,7 +6347,7 @@ input[disabled], select[disabled] { background: url("/images/menu-ico/ico-4-active.png") 100% 50% no-repeat ; } .admin-specialization-selected {overflow: hidden;} -.admin-specialization-selected ul {float: left; width: 740px; margin-left: -20px; margin-top: -8px;} +.admin-specialization-selected ul {float: left; width: 740px; margin-left: -20px; margin-top: -9px;margin-bottom: 0} .admin-specialization-selected ul li { text-decoration: none; font-size: 13px; @@ -6365,4 +6368,8 @@ input[disabled], select[disabled] { top: 1px; right: -9px; background: url("/images/delete-ico-min.png")no-repeat; +} +.admn-menu-err .help-block{ + width: 245px; + margin-left: -5px; } \ No newline at end of file -- libgit2 0.21.4