This commit is contained in:
2026-04-08 10:05:25 +08:00
parent 594aa137ef
commit b0e87b3fb3
34 changed files with 128 additions and 54 deletions
+6 -4
View File
@@ -176,10 +176,12 @@ class CommonController extends BaseController{
//邀请码
//$invite_code = 'TEAJXLEE';
$region = Input('region','+86');
$region = str_replace('+','',$region);
$extends = [
'role_id' => 1,
'group_id' => 0,
'region' => '86',
'region' => $region,
'nickname' => input('nickname'),
'avatar' => '/static/avatar/'.rand(0,17).'.png',
];
@@ -331,7 +333,7 @@ class CommonController extends BaseController{
}else{
if ($mobile && Validate::regex($mobile, "^1\d{10}$")) {
captcha_verify('mobile','reset_pwd',$mobile);
$region = Input('region');
$region = Input('region','+86');
$region = str_replace('+','',$region);
$user = UserModel::where('region',$region)->where('mobile',$mobile)->find();
}else if ($email && Validate::is($email, "email")) {
@@ -434,7 +436,7 @@ class CommonController extends BaseController{
$user = \support\Jwt::getUser();
$email = $user->email;
} catch (\Exception $th) {
return $this->error(__('Incoret param'));
return $this->error(__('Invalid parameter'));
}
}
$key = 'captcha_'.$event.'_'.$email;
@@ -467,7 +469,7 @@ class CommonController extends BaseController{
$user = \support\Jwt::getUser();
$mobile = $user->mobile;
} catch (\Exception $th) {
return $this->error(__('Incoret param'));
return $this->error(__('Invalid parameter'));
}
}
if (!Validate::regex($mobile, "^1\d{10}$")) {