From b8c1f7cef0f47e0a09d0c84c1012e9996664fafe Mon Sep 17 00:00:00 2001 From: Arsen Mirzaev Tatyano-Muradovich Date: Thu, 25 Feb 2021 03:10:29 +1000 Subject: [PATCH] =?UTF-8?q?=D0=98=D1=81=D0=BF=D1=80=D0=B0=D0=B2=D0=BB?= =?UTF-8?q?=D0=B5=D0=BD=D0=B8=D0=B5=20=D0=BE=D1=88=D0=B8=D0=B1=D0=BE=D0=BA?= =?UTF-8?q?=20=D1=81=20=D1=82=D0=B5=D0=B3=D0=B0=D0=BC=D0=B8?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- mirzaev/skillparts/system/models/AccountForm.php | 9 ++++++--- .../skillparts/system/views/account/authentication.php | 2 +- mirzaev/skillparts/system/views/account/index.php | 2 +- 3 files changed, 8 insertions(+), 5 deletions(-) diff --git a/mirzaev/skillparts/system/models/AccountForm.php b/mirzaev/skillparts/system/models/AccountForm.php index 3b6a5ba..bcd473d 100644 --- a/mirzaev/skillparts/system/models/AccountForm.php +++ b/mirzaev/skillparts/system/models/AccountForm.php @@ -1,9 +1,12 @@ user->login($this->getAccount(), $this->auto ? 3600 * 24 * 30 : 0); + return yii::$app->user->login($this->getAccount(), $this->auto ? 3600 * 24 * 30 : 0); } return false; @@ -113,7 +116,7 @@ class AccountForm extends Model // Запись параметров $this->account->mail = $this->mail; - $this->account->pswd = Yii::$app->security->generatePasswordHash($this->pswd); + $this->account->pswd = yii::$app->security->generatePasswordHash($this->pswd); // Регистрация return $this->account->save(); diff --git a/mirzaev/skillparts/system/views/account/authentication.php b/mirzaev/skillparts/system/views/account/authentication.php index abfb715..76715be 100644 --- a/mirzaev/skillparts/system/views/account/authentication.php +++ b/mirzaev/skillparts/system/views/account/authentication.php @@ -12,7 +12,7 @@ use yii; \ No newline at end of file diff --git a/mirzaev/skillparts/system/views/account/index.php b/mirzaev/skillparts/system/views/account/index.php index 933bc9b..938f0a7 100644 --- a/mirzaev/skillparts/system/views/account/index.php +++ b/mirzaev/skillparts/system/views/account/index.php @@ -40,7 +40,7 @@ use app\models\AccountForm; 'submitRegistration', 'onclick' => 'registration(this.parentElement);', 'class' => 'col-12 ml-auto btn btn-success btn-sm button_clean']) ?> - + \ No newline at end of file