Commit 41f4cbf8 by 冷斌

fix bug

parent c5dc6605
......@@ -631,9 +631,9 @@ class PassportAction extends CommonAction
$this->mzError($this->_register_model->getError());
}
//检查验证码
// if (!captcha_check($_POST['verify'], 'register')) {
// $this->mzError('验证码错误');
// }
if (!captcha_check($_POST['verify'], 'register')) {
$this->mzError('验证码错误');
}
$map['login'] = $email;
$map['email'] = $email;
} else {
......@@ -641,9 +641,9 @@ class PassportAction extends CommonAction
$this->mzError("手机号格式错误");
}
$phonedata = M('ResphoneCode')->where(['phone'=>$phone,'stime'=>['gt',time()-300]])->order('stime desc')->field('phone,code')->find();
// if ($phone != $phonedata['phone'] || $_POST['verify'] != $phonedata['code']) {
// $this->mzError("验证码错误");
// }
if ($phone != $phonedata['phone'] || $_POST['verify'] != $phonedata['code']) {
$this->mzError("验证码错误");
}
$map['phone'] = $phone;
$map['login'] = $phone;
......
......@@ -128,7 +128,8 @@
count: 60,
phone: "",
code: "",
password: ""
password: "",
invite_code: ""
}
},
computed: {
......@@ -149,7 +150,7 @@
let uname = "用户" + parseInt(Math.random() * 1000)//获取用户昵称
let password = this.password//获取密码
let mhm_id = ''//机构
let invite_code = ''//邀请码
let invite_code = "{$_GET['invite_code']}"//邀请码
$.ajax({
async:false,
type: "POST",
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment