忘记密码规则提示修改

master
zhanglingsheng 5 years ago
parent 2cf9e5e2e8
commit 23329c86b6

@ -1115,8 +1115,11 @@ class UserController extends BaseController
if ($user['code_type'] != 2) {
$this -> sms_verify($user['phone'], $user['code']);
}
if(!preg_match('/^(?![^a-zA-Z]+$)(?!\D+$).{6,15}$/', $user['password'])){
$this -> set_message(1027, "fail", "密码必须6-15位字母和数字组合");
// if(!preg_match('/^(?![^a-zA-Z]+$)(?!\D+$).{6,15}$/', $user['password'])){
// $this -> set_message(1027, "fail", "密码必须6-15位字母和数字组合");
// }
if(!preg_match('/^[0-9a-zA-Z]{6,12}$/', $user['password'])){
$this -> set_message(1027, "fail", "密码长度为6-12位");
}
$result = $userApi -> updatePassword($user['user_id'], $user['password']);

Loading…
Cancel
Save