Commit f61f63e2702b03c74f6924efdc2d79f82389aab1

Authored by Виталий
1 parent fa49386b

tokar commit

frontend/controllers/SiteController.php
... ... @@ -93,6 +93,11 @@ class SiteController extends Controller
93 93 return $out;
94 94 }
95 95  
  96 + public function actionFormsModalLogin()
  97 + {
  98 + return $this->renderAjax('forms-modal-login', []);
  99 + }
  100 +
96 101 public function actionFormsModalContacts()
97 102 {
98 103 return $this->renderAjax('forms-modal-contacts', []);
... ...
frontend/views/layouts/main.php
... ... @@ -51,7 +51,7 @@ AppAsset::register($this);
51 51 </div>
52 52 <div class="header-cabinet-profile not-login">Профиль</div>
53 53 <div>
54   - <?= Html::a('Вход',['/site/login']) ?>
  54 + <?= Html::a('Вход',['/site/login'], ['class'=>'loginLinkModal']) ?>
55 55 <?= Html::a('Регистрация',['/site/registration']) ?>
56 56 </div>
57 57  
... ...
frontend/views/site/forms-modal-login.php 0 → 100644
  1 +<?php
  2 +use common\models\LoginForm;
  3 +use yii\helpers\Html;
  4 +use yii\widgets\ActiveForm;
  5 +
  6 +?>
  7 +
  8 +
  9 +
  10 +<!--<div id="modal_form_login">-->
  11 +<!-- <div class="closed-form"></div>-->
  12 +<!-- <div class="form-resume-wr question">-->
  13 +<!-- <div class="form-resume-sub style">Авторизация</div>-->
  14 +<!-- <form action="" class="question-project">-->
  15 +<!-- <label for="login-form1">Логин</label>-->
  16 +<!-- <input class="custom-input-2" id="login-form1" name="" type="text">-->
  17 +<!---->
  18 +<!-- <label for="login-form2">Пароль</label>-->
  19 +<!-- <input class="custom-input-2" id="login-form2" name="" type="text">-->
  20 +<!---->
  21 +<!-- <div class="login-check-remember">-->
  22 +<!-- <input checked type="checkbox" class="custom-check" id="theme-5">-->
  23 +<!-- <label for="theme-5"><span></span>Запомнить меня</label>-->
  24 +<!-- </div>-->
  25 +<!---->
  26 +<!---->
  27 +<!-- -->
  28 +<!-- <input id="qst_submit" type="submit" value="Отправить">-->
  29 +<!-- </form>-->
  30 +<!-- <div class="res_form_line"></div>-->
  31 +<!-- </div>-->
  32 +<!--</div>-->
  33 +
  34 +<div id="modal_form_login">
  35 + <div class="closed-form"></div>
  36 + <div class="form-resume-wr question">
  37 + <div class="form-resume-sub style">Авторизация</div>
  38 + <?php $form = ActiveForm::begin([
  39 + 'options' => [
  40 + 'class' => 'form-horizontal',
  41 + 'id' => 'login-form',
  42 + ],
  43 + ]); ?>
  44 + <?php echo $form->field($model, 'username')
  45 + ->textInput(); ?>
  46 + <?php echo $form->field($model, 'password')
  47 + ->passwordInput(); ?>
  48 + <?php echo $form->field($model, 'rememberMe')
  49 + ->checkbox(); ?>
  50 + <div class="form-actions">
  51 + <?php echo Html::submitButton('Login', [ 'class' => 'btn btn-primary' ]); ?>
  52 + </div>
  53 + <?= Html::a('Восстановить пароль', [ 'site/request-password-reset' ]) ?>
  54 + <?php ActiveForm::end(); ?>
  55 + <div class="res_form_line"></div>
  56 + </div>
  57 +</div>
0 58 \ No newline at end of file
... ...
frontend/web/css/style.css
... ... @@ -950,7 +950,6 @@ li.project-home-active span{
950 950 font-weight: 700;
951 951 width: 100%;
952 952 float: left;
953   - margin-bottom: 5px;
954 953 }
955 954 .form-resume-wr form input {
956 955 width: 240px;
... ... @@ -959,6 +958,7 @@ li.project-home-active span{
959 958 box-sizing: border-box;
960 959 padding-left: 10px;
961 960 margin-bottom: 13px;
  961 + margin-top: 5px;
962 962 }
963 963 .form-resume-wr form textarea {
964 964 width: 240px;
... ... @@ -3373,7 +3373,7 @@ ul.proektant-comments {margin-top: 15px}
3373 3373 background:url("/images/menu_icons.png") -44px 0 no-repeat;
3374 3374 }
3375 3375 /***modal***/
3376   -#modal_form_favorite, #modal_form_offer, #modal_form_question {
  3376 +#modal_form_favorite, #modal_form_offer, #modal_form_question, #modal_form_login {
3377 3377 width: 460px;
3378 3378 height: 263px;
3379 3379 position: absolute;
... ... @@ -3385,6 +3385,7 @@ ul.proektant-comments {margin-top: 15px}
3385 3385 z-index: 9992;
3386 3386 }
3387 3387 #modal_form_question {height: 533px}
  3388 +#modal_form_login {height: 423px}
3388 3389 #modal_form_favorite .res_form_line {bottom: 85px}
3389 3390 .page-favorite {
3390 3391 height: 85px;
... ... @@ -4104,7 +4105,7 @@ ul.min_markers_two
4104 4105 .comments_block{width:938px;height:498px;background-color:#fcfcfc;border:1px solid #b7b7b7;border-right:none;margin-bottom:57px;color:#333;font-family:Roboto;font-size:13px;position:relative;overflow:hidden;outline:none}.comment_type{width:940px}.comment_type .pole{width:660px;margin:0 auto;position:relative}.comment_type .mes_title{font-size:18px;color:#333;margin:18px 0}.message_text{width:638px;height:78px;resize:none;border:1px solid #c2c2c2;margin:0 auto;margin-bottom:26px;margin-top:18px;padding:10px;font-family:Roboto}.send_mess_but{outline:none;border:none;cursor:pointer;font-size:12px!important;padding-top:2px;width:170px;height:43px;text-align:center;text-transform:uppercase;filter:progid:DXImageTransform.Microsoft.gradient(startColorstr = '#148ad6',endColorstr = '#0072bc');-ms-filter:"progid:DXImageTransform.Microsoft.gradient(startColorstr = '#148ad6',endColorstr = '#0072bc')";background-image:-moz-linear-gradient(top,#148ad6,#0072bc);background-image:-ms-linear-gradient(top,#148ad6,#0072bc);background-image:-o-linear-gradient(top,#148ad6,#0072bc);background-image:-webkit-gradient(linear,center top,center bottom,from(#148ad6),to(#0072bc));background-image:-webkit-linear-gradient(top,#148ad6,#0072bc);background-image:linear-gradient(top,#148ad6,#0072bc);color:#fff;border-bottom:2px solid #0054a6;border-radius:4px;transition:.1s;top:170px;line-height:3.5}.send_mess_but:hover{opacity:.9}.send_mess_but:active{line-height:3.7}.pick_file{position:absolute;top:170px;right:0;width:130px}.pick_file .link:after{content:'';background:url(/images/skrpk.png) left center no-repeat;position:absolute;width:19px;height:21px;left:-28px;top:0}.pick_file .link{text-transform:uppercase;color:#0276c0;font-size:13px;cursor:pointer;text-decoration:none;border-bottom:1px solid #70b2db;position:relative}.pick_file .capt{color:#c2c2c2;font-size:11px;line-height:16px;margin-top:3px}.comment_text{position:relative;padding:12px 13px;width:602px;border:1px solid #c2c2c2;min-height:74px;left:10px;line-height:1.3;background-color:#fff}.comment.left .comment_text{float:left}.comment.right .comment_text{float:right}.comment.left .comment_text:before{content:'';background:url(/images/mes_bord_left.png);position:absolute;width:11px;height:11px;top:-1px;left:-11px}.comment.right .comment_text:before{content:'';background:url(/images/mes_bord_right.png);position:absolute;width:11px;height:11px;top:-1px;right:-11px}.comment.left .author_pic{float:left;margin:0 10px}.comment.right .author_pic{float:right;margin:0 25px 0 30px}.comment_time{color:#c6c6c6;font-family:Roboto;font-size:13px;font-weight:600;line-height:32px;position:absolute}.comment.left .comment_time{top:17px;right:-64px}.comment.right .comment_time{top:18px;left:-64px}.comment{position:relative;margin:30px 21px 30px 1px}.comment .offer_link a{color:#0173bd;position:relative}.comment .offer_link a:before{content:'';position:absolute;background:url(/images/skrpk_sm.png) left center no-repeat;width:19px;height:21px;left:-26px;top:-3px}.comment.right .offer_link{float:right;margin-right:94px;margin-top:12px;margin-bottom:-17px}.comment.left .offer_link{left:104px;bottom:-27px}.comment_block .content{overflow:auto;width:938px;height:498px}.fileform{background-color:#FFF;border:1px solid #CCC;border-radius:2px;cursor:pointer;height:26px;overflow:hidden;padding:2px;position:relative;text-align:left;vertical-align:middle;width:230px}.comment_type form{width:660px;margin:0 auto}.comment_type form label{color:#333;font-family:Roboto;font-size:18px}.input_file_text{color:#c2c2c2;font-size:11px;font-family:Roboto;width:125px;position:absolute;right:0;line-height:16px;top:18px;overflow:hidden;text-overflow:ellipsis;white-space:pre-line}.inputfile{float:right;position:relative;width:153px;padding-bottom:10px;background:url(/images/skrpk.png);background-repeat:no-repeat}.input_file{opacity:0;cursor:pointer;width:160px}.inputfile .file_input_title{position:absolute;color:#0276c0;border-bottom:1px solid #0276c0;text-transform:uppercase;font-family:Roboto;font-size:13px;right:0}.jspArrow{background-color:#0173bd;width:20px;height:20px}.jspVerticalBar{width:20px}.jspVerticalBar .jspArrow{height:20px}.jspTrack{background:#ebebeb;position:relative}.jspDrag{background:#c2c2c2;position:relative;top:0;left:0;cursor:pointer;border-left:2px solid #ebebeb;border-right:2px solid #ebebeb}.jspVerticalBar{background:#ebebeb}.jspArrowUp{background:#0173bd url(/images/scroll_up.png) center center no-repeat}.jspArrowUp:hover{opacity:.8}.jspArrowUp:active{background-position-y:1px!important}.jspDisabled.jspArrowUp{background:#80808d url(/images/scroll_up_grey.png) center center no-repeat}.jspArrowDown{background:#0173bd url(/images/scroll_down.png) center center no-repeat}.jspArrowDown:hover{opacity:.8}.jspArrowDown:active{background-position-y:1px!important}.jspArrowDown{background:#0173bd url(/images/scroll_down.png) center center no-repeat}.jspDisabled.jspArrowDown{background:#80808d url(/images/scroll_down_grey.png) center center no-repeat}.jspContainer{outline:none;border:none}
4105 4106 /***form-order***/
4106 4107 #modal_form_offer {height: 505px;}
4107   -#modal_form_offer,#modal_form_question{margin-top: 70px;}
  4108 +#modal_form_offer,#modal_form_question, #modal_form_question{margin-top: 70px;}
4108 4109 .form-resume-wr form input[type="submit"]{margin-left: 55px;}
4109 4110 .form-resume-wr form{top:72px;}
4110 4111 .form-resume-wr.offer form textarea {
... ... @@ -5301,7 +5302,12 @@ input.disabled.admin-check:checked + label, input.disabled.admin-check:checked +
5301 5302 float: right;
5302 5303 margin-right: -5px;
5303 5304 }
5304   -
  5305 +.who-you-are input.custom-radio + label span, .who-you-are input.custom-check + label span{margin-top: 2px}
  5306 +.login-check-remember label{
  5307 + margin-left: 6px !important;
  5308 + width: auto !important;
  5309 +}
  5310 +.login-check-remember label span {margin-left: 0 !important;margin-top: 2px !important;}
5305 5311  
5306 5312  
5307 5313  
... ...
frontend/web/images/arrow-main-menu.png

544 Bytes | W: | H:

142 Bytes | W: | H:

  • 2-up
  • Swipe
  • Onion skin
frontend/web/images/arrow-search.png

2.83 KB | W: | H:

143 Bytes | W: | H:

  • 2-up
  • Swipe
  • Onion skin
frontend/web/images/artweb.png

953 Bytes | W: | H:

827 Bytes | W: | H:

  • 2-up
  • Swipe
  • Onion skin
frontend/web/images/ico-contact.png

886 Bytes | W: | H:

431 Bytes | W: | H:

  • 2-up
  • Swipe
  • Onion skin
frontend/web/images/ico-fed-1.png

1.27 KB | W: | H:

1.17 KB | W: | H:

  • 2-up
  • Swipe
  • Onion skin
frontend/web/images/ico-fed-2.png

1.54 KB | W: | H:

1.38 KB | W: | H:

  • 2-up
  • Swipe
  • Onion skin
frontend/web/images/ico-fed-3.png

1.26 KB | W: | H:

1.13 KB | W: | H:

  • 2-up
  • Swipe
  • Onion skin
frontend/web/images/ico-profile.png

998 Bytes | W: | H:

473 Bytes | W: | H:

  • 2-up
  • Swipe
  • Onion skin
frontend/web/images/ico-question.png

789 Bytes | W: | H:

365 Bytes | W: | H:

  • 2-up
  • Swipe
  • Onion skin
frontend/web/images/ico-search.png

754 Bytes | W: | H:

299 Bytes | W: | H:

  • 2-up
  • Swipe
  • Onion skin
frontend/web/images/logo.png

3.25 KB | W: | H:

2.38 KB | W: | H:

  • 2-up
  • Swipe
  • Onion skin
frontend/web/images/menu-pic-1.jpg

19 KB | W: | H:

18.2 KB | W: | H:

  • 2-up
  • Swipe
  • Onion skin
frontend/web/images/sect-bg-1.jpg

134 KB | W: | H:

133 KB | W: | H:

  • 2-up
  • Swipe
  • Onion skin
frontend/web/images/sect-bg-4.jpg

27.5 KB | W: | H:

26.6 KB | W: | H:

  • 2-up
  • Swipe
  • Onion skin
frontend/web/images/shadow-map.png

478 Bytes | W: | H:

83 Bytes | W: | H:

  • 2-up
  • Swipe
  • Onion skin
frontend/web/images/soc-ico-2.png

3.03 KB | W: | H:

2.96 KB | W: | H:

  • 2-up
  • Swipe
  • Onion skin
frontend/web/images/soc-ico-4.png

3.02 KB | W: | H:

2.88 KB | W: | H:

  • 2-up
  • Swipe
  • Onion skin
frontend/web/js/forms.js
... ... @@ -4,6 +4,25 @@ $(document).ready(function(){
4 4 $('body').append('<div id="overlay"></div>').append('<div class="forms-modal-hide"></div>');
5 5 }
6 6  
  7 + function addToLogin(){
  8 + $.post("/site/forms-modal-login", function (data) {
  9 + $('.forms-modal-hide').append(data)
  10 + })
  11 + .fail(function(){
  12 + $('#overlay, .forms-modal-hide').remove();
  13 + alert(txtErrorModal)
  14 + })
  15 + .done(function() {
  16 + var newMarg = $(window).scrollTop();
  17 + $('#overlay').fadeIn(400,
  18 + function(){
  19 + $('.forms-modal-hide>div')
  20 + .css({display:'block', marginTop:-230+newMarg})
  21 + .animate({opacity: 1, top: '50%'}, 200);
  22 + });
  23 + })
  24 + }
  25 +
7 26 function addToFavorites(){
8 27 $.post("/site/forms-modal-fav", function (data) {
9 28 $('.forms-modal-hide').append(data)
... ... @@ -61,6 +80,12 @@ $(document).ready(function(){
61 80 })
62 81 }
63 82  
  83 + //login
  84 + $('a.loginLinkModal').click(function(e){
  85 + e.preventDefault()
  86 + addRemoveBlocks()
  87 + addToLogin()
  88 + })
64 89 //contacts
65 90 $('a.contactsLinkModalFirst').click(function(e){
66 91 e.preventDefault()
... ...