正在显示
1 个修改的文件
包含
2 行增加
和
1 行删除
| @@ -65,6 +65,7 @@ class UserLoginLogic | @@ -65,6 +65,7 @@ class UserLoginLogic | ||
| 65 | * @time :2023/6/12 15:31 | 65 | * @time :2023/6/12 15:31 |
| 66 | */ | 66 | */ |
| 67 | public function verifyAccount(){ | 67 | public function verifyAccount(){ |
| 68 | + //密码加密 | ||
| 68 | $password = base64_encode(md5($this->param['password'])); | 69 | $password = base64_encode(md5($this->param['password'])); |
| 69 | $info = $this->model->read(['mobile'=>$this->param['mobile'],'password'=>$password,'status'=>$this::USER_STATUS], | 70 | $info = $this->model->read(['mobile'=>$this->param['mobile'],'password'=>$password,'status'=>$this::USER_STATUS], |
| 70 | ['id','mobile','role_id','token','name','project_id']); | 71 | ['id','mobile','role_id','token','name','project_id']); |
| @@ -74,7 +75,7 @@ class UserLoginLogic | @@ -74,7 +75,7 @@ class UserLoginLogic | ||
| 74 | if($this->param['password'] != $last_sms->code){ | 75 | if($this->param['password'] != $last_sms->code){ |
| 75 | $this->fail('账号密码错误/验证码错误',Code::USER_REGISTER_ERROE); | 76 | $this->fail('账号密码错误/验证码错误',Code::USER_REGISTER_ERROE); |
| 76 | } | 77 | } |
| 77 | - $info = $this->model->read(['mobile'=>$this->param['mobile']],['id','mobile','role_id','token','name','project_id']); | 78 | + $info = $this->model->read(['mobile'=>$this->param['mobile']],['id','mobile','status','role_id','token','name','project_id']); |
| 78 | if($info === false){ | 79 | if($info === false){ |
| 79 | $this->fail('当前用户不存在',Code::USER_REGISTER_ERROE); | 80 | $this->fail('当前用户不存在',Code::USER_REGISTER_ERROE); |
| 80 | } | 81 | } |
-
请 注册 或 登录 后发表评论