用户登录逻辑修改

main
ztt 8 months ago
parent d269d35d24
commit 5818086533
  1. 4
      addons/shopro/controller/Index.php

@ -173,7 +173,9 @@ class Index extends Common
$this->error(__('手机号已经被占用')); $this->error(__('手机号已经被占用'));
} elseif (in_array($event, ['changepwd', 'resetpwd', 'mobilelogin']) && !$userinfo) { } elseif (in_array($event, ['changepwd', 'resetpwd', 'mobilelogin']) && !$userinfo) {
//未注册 注册手机号 //未注册 注册手机号
$this->auth->register($mobile, $mobile, '', $mobile, ''); $userAuth = new UserAuth();
$auth = $userAuth->register(['mobile' => $mobile]);
set_token_in_header($auth->getToken());
// set_token_in_header($auth->getToken()); // set_token_in_header($auth->getToken());
// $this->error(__('手机号未注册')); // $this->error(__('手机号未注册'));
} }

Loading…
Cancel
Save