Commit f7c9f6f9 authored by 董先生's avatar 董先生

持仓列表

parent 4098f95a
...@@ -165,34 +165,34 @@ class User extends Common ...@@ -165,34 +165,34 @@ class User extends Common
public function sendsms() public function sendsms()
{ {
$mobile = input('mobile'); $mobile = input('mobile');
$phonecode = input('phonecode'); // $phonecode = input('phonecode');
$data['mobile'] = $mobile; $data['mobile'] = $mobile;
$data['captcha'] = $phonecode; // $data['captcha'] = $phonecode;
$result = $this->validate($data, 'Member.reg'); /* $result = $this->validate($data, 'Member.reg');
if(true !== $result){ if(true !== $result){
// 验证失败 输出错误信息 // 验证失败 输出错误信息
ajaxmsg($result,0); ajaxmsg($result,0);
} }
$tp = 'code'; $tp = 'code';*/
$ret=MemberModel::getMemberInfoByMobile($mobile); $ret=MemberModel::getMemberInfoByMobile($mobile);
if(!empty($ret)) ajaxmsg('该手机已经注册会员,请更换手机!',0); if(!empty($ret)) ajaxmsg('该手机已经注册会员,请更换手机!',0);
if(input('captcha')){ /*if(input('captcha')){
$captcha = ['captcha'=>input('captcha'), 'mobile'=>$mobile]; $captcha = ['captcha'=>input('captcha'), 'mobile'=>$mobile];
// 验证码 // 验证码
$result = $this->validate($captcha, 'Member.captcha'); $result = $this->validate($captcha, 'Member.captcha');
if(true !== $result){ if(true !== $result){
ajaxmsg($result,0); ajaxmsg($result,0);
}; };
} }*/
if(!check_sms_code($mobile)){ /* if(!check_sms_code($mobile)){
ajaxmsg('请间隔60秒再获取验证码!',0); ajaxmsg('请间隔60秒再获取验证码!',0);
} }*/
// $res = send_sms($mobile, $template); // $res = send_sms($mobile, $template);
$content = \think\Config::get('sms_template')['register']; // $content = \think\Config::get('sms_template')['register'];
$content = str_replace(array("#var#"),array($mobile), $content); // $content = str_replace(array("#var#"),array($mobile), $content);
// $res = sendsms_mandao($mobile,$content,$tp); // $res = sendsms_mandao($mobile,$content,$tp);
$zthysms = new ZthySms(); $zthysms = new ZthySms();
$res = $zthysms->sendSmsCode($mobile); $res = $zthysms->sendSmsCode($mobile);
......
...@@ -29,8 +29,7 @@ class ZthySms ...@@ -29,8 +29,7 @@ class ZthySms
); );
$ret = self::httpPost($url, $date); $ret = self::httpPost($url, $date);
$res = json_decode($ret, true); $res = json_decode($ret, true);
if($res['code'] != 200){
if(res['code'] != 200){
return false; return false;
} }
$code = $code; $code = $code;
......
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