|
|
@ -250,7 +250,14 @@ class UserController extends AdminController {
|
|
|
|
if($password != $repassword){
|
|
|
|
if($password != $repassword){
|
|
|
|
$this->error('管理员密码和确认密码不一致!');
|
|
|
|
$this->error('管理员密码和确认密码不一致!');
|
|
|
|
}
|
|
|
|
}
|
|
|
|
|
|
|
|
$usernameUser = M('UcenterMember', 'sys_')->field('username')->where(['username' => $username])->find();
|
|
|
|
|
|
|
|
if (!empty($usernameUser)) {
|
|
|
|
|
|
|
|
$this->error('用户名已存在!');
|
|
|
|
|
|
|
|
}
|
|
|
|
|
|
|
|
$emailUser = M('UcenterMember', 'sys_')->field('username')->where(['username' => $username])->find();
|
|
|
|
|
|
|
|
if (!empty($emailUser)) {
|
|
|
|
|
|
|
|
$this->error('邮箱已存在!');
|
|
|
|
|
|
|
|
}
|
|
|
|
/* 调用注册接口注册用户 */
|
|
|
|
/* 调用注册接口注册用户 */
|
|
|
|
$User = new UserApi;
|
|
|
|
$User = new UserApi;
|
|
|
|
$uid = $User->register($username, $password, $email,$second_pwd);
|
|
|
|
$uid = $User->register($username, $password, $email,$second_pwd);
|
|
|
|