Commit 8fe601f0d5e626b76593103ac1141d1ef6947bfa
1 parent
cec2889f
Веталь
Showing
3 changed files
with
124 additions
and
4 deletions
Show diff stats
backend/models/LoginForm.php
| @@ -76,4 +76,18 @@ class LoginForm extends Model | @@ -76,4 +76,18 @@ class LoginForm extends Model | ||
| 76 | 76 | ||
| 77 | return $this->_user; | 77 | return $this->_user; |
| 78 | } | 78 | } |
| 79 | + | ||
| 80 | + /** | ||
| 81 | + * @inheritdoc | ||
| 82 | + */ | ||
| 83 | + public function attributeLabels() | ||
| 84 | + { | ||
| 85 | + return [ | ||
| 86 | + | ||
| 87 | + 'username' => 'Имя пользователя', | ||
| 88 | + 'password' => 'Пароль', | ||
| 89 | + 'rememberMe' => 'Запомнить пароль', | ||
| 90 | + | ||
| 91 | + ]; | ||
| 92 | + } | ||
| 79 | } | 93 | } |
backend/views/site/login.php
| @@ -12,13 +12,15 @@ $this->params['breadcrumbs'][] = $this->title; | @@ -12,13 +12,15 @@ $this->params['breadcrumbs'][] = $this->title; | ||
| 12 | ?> | 12 | ?> |
| 13 | <div class="site-login"> | 13 | <div class="site-login"> |
| 14 | <div class="container"> | 14 | <div class="container"> |
| 15 | - <h1><?= Html::encode($this->title) ?></h1> | ||
| 16 | 15 | ||
| 17 | - <p>Please fill out the following fields to login:</p> | ||
| 18 | 16 | ||
| 19 | <div class="row"> | 17 | <div class="row"> |
| 20 | <div class="col-xs-3"></div> | 18 | <div class="col-xs-3"></div> |
| 21 | - <div class="col-lg-6"> | 19 | + <div class="col-lg-6 new_admin_form"> |
| 20 | + <div class="artbox_logo-wr"><div class="artbox_logo">ArtBox</div></div> | ||
| 21 | + <div class="artbox_logo_txt">управление интернет магазином</div> | ||
| 22 | +<!-- <h1>--><?//= Html::encode($this->title) ?><!--</h1>--> | ||
| 23 | +<!-- <p>Пожалуйста, заполните следующие поля для входа</p>--> | ||
| 22 | <?php $form = ActiveForm::begin(['id' => 'login-form']); ?> | 24 | <?php $form = ActiveForm::begin(['id' => 'login-form']); ?> |
| 23 | 25 | ||
| 24 | <?= $form->field($model, 'username')->textInput(['autofocus' => true]) ?> | 26 | <?= $form->field($model, 'username')->textInput(['autofocus' => true]) ?> |
| @@ -28,7 +30,7 @@ $this->params['breadcrumbs'][] = $this->title; | @@ -28,7 +30,7 @@ $this->params['breadcrumbs'][] = $this->title; | ||
| 28 | <?= $form->field($model, 'rememberMe')->checkbox() ?> | 30 | <?= $form->field($model, 'rememberMe')->checkbox() ?> |
| 29 | 31 | ||
| 30 | <div class="form-group"> | 32 | <div class="form-group"> |
| 31 | - <?= Html::submitButton('Login', ['class' => 'btn btn-primary', 'name' => 'login-button']) ?> | 33 | + <?= Html::submitButton('Войти', ['class' => 'btn btn-primary', 'name' => 'login-button']) ?> |
| 32 | </div> | 34 | </div> |
| 33 | 35 | ||
| 34 | <?php ActiveForm::end(); ?> | 36 | <?php ActiveForm::end(); ?> |
backend/web/css/site.css
| @@ -103,3 +103,107 @@ a.desc:after { | @@ -103,3 +103,107 @@ a.desc:after { | ||
| 103 | .nav > li > form > button:hover { | 103 | .nav > li > form > button:hover { |
| 104 | text-decoration: none; | 104 | text-decoration: none; |
| 105 | } | 105 | } |
| 106 | +.new_admin_form input { | ||
| 107 | + border: 1px solid #95ba2f !important; | ||
| 108 | +} | ||
| 109 | +.new_admin_form h1, .new_admin_form p, .new_admin_form label {color: #bdbdbd !important; font-weight: 400 !important;} | ||
| 110 | +.new_admin_form .btn { | ||
| 111 | + background: #95ba2f !important; | ||
| 112 | + border-radius: 4px !important; | ||
| 113 | + height: 29px !important; | ||
| 114 | + text-transform: uppercase !important; | ||
| 115 | + color: #ffffff !important; | ||
| 116 | + text-decoration: none !important; | ||
| 117 | + font-weight: 600 !important; | ||
| 118 | + text-align: center !important; | ||
| 119 | + border-bottom: 3px solid #799920 !important; | ||
| 120 | + font-size: 12px !important; | ||
| 121 | + outline: none !important; | ||
| 122 | + border-top: none; | ||
| 123 | + border-left: none; | ||
| 124 | + border-right: none; | ||
| 125 | +} | ||
| 126 | +.new_admin_form .btn:focus { | ||
| 127 | + box-shadow: none !important; | ||
| 128 | +} | ||
| 129 | +.new_admin_form .btn:hover { | ||
| 130 | + border-bottom: 3px solid #95ba2f !important; | ||
| 131 | +} | ||
| 132 | +.new_admin_form .btn:active { | ||
| 133 | + border-bottom: 3px solid #799920 !important; | ||
| 134 | + background: #799920 !important; | ||
| 135 | +} | ||
| 136 | +.artbox_logo-wr { | ||
| 137 | + perspective: 250px; | ||
| 138 | +} | ||
| 139 | +.artbox_logo { | ||
| 140 | + text-align: center; | ||
| 141 | + font-size: 42px; | ||
| 142 | + color: #fff; | ||
| 143 | + text-transform: uppercase; | ||
| 144 | + margin-top: 9px; | ||
| 145 | + -webkit-animation-name:anim_artbox; | ||
| 146 | + -moz-animation-name:anim_artbox; | ||
| 147 | + animation-name:anim_artbox; | ||
| 148 | + -webkit-animation-duration:4.7s; | ||
| 149 | + -moz-animation-duration:4.7s; | ||
| 150 | + animation-duration:4.7s; | ||
| 151 | + -webkit-animation-timing-function:linear; | ||
| 152 | + -moz-animation-timing-function:linear; | ||
| 153 | + animation-timing-function:linear; | ||
| 154 | + -webkit-animation-iteration-count:infinite; | ||
| 155 | + -moz-animation-iteration-count:infinite; | ||
| 156 | + animation-iteration-count:infinite; | ||
| 157 | + /*-webkit-animation-play-state:running;*/ | ||
| 158 | + /*-moz-animation-play-state:running;*/ | ||
| 159 | + /*animation-play-state:running*/ | ||
| 160 | + -webkit-animation-play-state:paused; | ||
| 161 | + -moz-animation-play-state:paused; | ||
| 162 | + animation-play-state:paused; | ||
| 163 | +} | ||
| 164 | +@-webkit-keyframes anim_artbox { | ||
| 165 | + 0% | ||
| 166 | + { | ||
| 167 | + -webkit-transform:rotateY(0deg) | ||
| 168 | + } | ||
| 169 | + | ||
| 170 | + 100% | ||
| 171 | + { | ||
| 172 | + -webkit-transform:rotateY(360deg) | ||
| 173 | + } | ||
| 174 | +} | ||
| 175 | + | ||
| 176 | +@-moz-keyframes anim_artbox { | ||
| 177 | + 0% | ||
| 178 | + { | ||
| 179 | + -moz-transform:rotateY(0deg) | ||
| 180 | + } | ||
| 181 | + | ||
| 182 | + 100% | ||
| 183 | + { | ||
| 184 | + -moz-transform:rotateY(360deg) | ||
| 185 | + } | ||
| 186 | +} | ||
| 187 | + | ||
| 188 | +@keyframes anim_artbox { | ||
| 189 | + 0% | ||
| 190 | + { | ||
| 191 | + transform:rotateY(0deg) | ||
| 192 | + } | ||
| 193 | + | ||
| 194 | + 100% | ||
| 195 | + { | ||
| 196 | + transform:rotateY(360deg) | ||
| 197 | + } | ||
| 198 | +} | ||
| 199 | +.artbox_logo_txt { | ||
| 200 | + text-align: center; | ||
| 201 | + font-size: 15px; | ||
| 202 | + color: #fff; | ||
| 203 | + margin-bottom: 11px; | ||
| 204 | +} | ||
| 205 | +.new_admin_form .help-block { | ||
| 206 | + color: #d80400 !important; | ||
| 207 | + text-align: center; | ||
| 208 | + font-size: 13px !important; | ||
| 209 | +} |