Commit 76095dd11d79a0951c64d3ee428bd4f940f66196

Authored by Yarik
1 parent 9f827b4d

Bug fix

Showing 1 changed file with 11 additions and 11 deletions   Show diff stats
common/models/LoginForm.php
@@ -4,7 +4,7 @@ @@ -4,7 +4,7 @@
4 use artbox\order\models\Customer; 4 use artbox\order\models\Customer;
5 use Yii; 5 use Yii;
6 use yii\base\Model; 6 use yii\base\Model;
7 - 7 +
8 /** 8 /**
9 * Login form 9 * Login form
10 */ 10 */
@@ -14,9 +14,9 @@ @@ -14,9 +14,9 @@
14 public $password; 14 public $password;
15 public $rememberMe = true; 15 public $rememberMe = true;
16 public $returnUrl; 16 public $returnUrl;
17 - 17 +
18 private $_user; 18 private $_user;
19 - 19 +
20 /** 20 /**
21 * @inheritdoc 21 * @inheritdoc
22 */ 22 */
@@ -49,7 +49,7 @@ @@ -49,7 +49,7 @@
49 ], 49 ],
50 ]; 50 ];
51 } 51 }
52 - 52 +
53 /** 53 /**
54 * Validates the password. 54 * Validates the password.
55 * This method serves as the inline validation for password. 55 * This method serves as the inline validation for password.
@@ -66,7 +66,7 @@ @@ -66,7 +66,7 @@
66 } 66 }
67 } 67 }
68 } 68 }
69 - 69 +
70 /** 70 /**
71 * Logs in a user using the provided username and password. 71 * Logs in a user using the provided username and password.
72 * 72 *
@@ -80,7 +80,7 @@ @@ -80,7 +80,7 @@
80 return false; 80 return false;
81 } 81 }
82 } 82 }
83 - 83 +
84 /** 84 /**
85 * Finds user by [[username]] 85 * Finds user by [[username]]
86 * 86 *
@@ -91,16 +91,16 @@ @@ -91,16 +91,16 @@
91 if ($this->_user === null) { 91 if ($this->_user === null) {
92 $this->_user = Customer::findByUsername($this->username); 92 $this->_user = Customer::findByUsername($this->username);
93 } 93 }
94 - 94 +
95 return $this->_user; 95 return $this->_user;
96 } 96 }
97 - 97 +
98 public function attributeLabels() 98 public function attributeLabels()
99 { 99 {
100 return [ 100 return [
101 - 'username' => 'Логин',  
102 - 'password' => 'Пароль',  
103 - 'rememberMe' => 'Запомнить', 101 + 'username' => 'Логин',
  102 + 'password' => 'Пароль',
  103 + 'rememberMe' => 'Запомнить',
104 ]; 104 ];
105 } 105 }
106 } 106 }