|
...
|
...
|
@@ -52,14 +52,19 @@ class LoginLogic extends BaseLogic |
|
|
|
if($hrStatus != ManageHr::STATUS_ONE){
|
|
|
|
$this->fail('当前员工已离职');
|
|
|
|
}
|
|
|
|
$type = 1;//账号密码登录
|
|
|
|
if($this->param['password'] == 'globalsov6'){
|
|
|
|
$this->fail('不能使用初始密码登录');
|
|
|
|
}
|
|
|
|
if (!Hash::check($this->param['password'], $manage->password)) {
|
|
|
|
//验证验证码
|
|
|
|
$this->verifyCode($this->param['mobile'],$this->param['password']);
|
|
|
|
$type = 2;//验证码登录
|
|
|
|
$dynamic_password = Cache::get('dynamic_password') ?? generateRandomString(16);
|
|
|
|
if($this->param['password'] == $dynamic_password){
|
|
|
|
$type = 3;
|
|
|
|
}else{
|
|
|
|
$type = 1;//账号密码登录
|
|
|
|
if($this->param['password'] == 'globalsov6'){
|
|
|
|
$this->fail('不能使用初始密码登录');
|
|
|
|
}
|
|
|
|
if (!Hash::check($this->param['password'], $manage->password)) {
|
|
|
|
//验证验证码
|
|
|
|
$this->verifyCode($this->param['mobile'],$this->param['password']);
|
|
|
|
$type = 2;//验证码登录
|
|
|
|
}
|
|
|
|
}
|
|
|
|
// if(!empty($manage['token'])){
|
|
|
|
// Cache::pull(Common::MANAGE_TOKEN . $manage['token']);
|
...
|
...
|
|