| | |
| | | $mobile = $this->request->post('mobile'); |
| | | $captcha = $this->request->post('captcha'); |
| | | $ismobouth=$this->request->post('ismobouth',false); |
| | | $push_cid=$this->request->post('push_cid',false); |
| | | $pushCid=$this->request->post('pushCid',false); |
| | | if (!$mobile || !$captcha) { |
| | | $this->error(__('Invalid parameters')); |
| | | } |
| | |
| | | //如果已经有账号则直接登录 |
| | | $ret = $this->auth->direct($user->id); |
| | | } else { |
| | | $ret = $this->auth->register($mobile, Random::alnum(), '', $mobile, []); |
| | | $ret = $this->auth->register($mobile, Random::alnum(), '', $mobile, [],'',[],$pushCid); |
| | | } |
| | | if ($ret) { |
| | | Sms::flush($mobile, 'login'); |