|
@ -1217,12 +1217,18 @@ public class WlyyLoginEndpoint extends AbstractEndpoint {
|
|
|
|
|
|
|
|
|
|
@RequestMapping(value = "/oauth/registerPatientAndLogin", method = RequestMethod.POST)
|
|
@RequestMapping(value = "/oauth/registerPatientAndLogin", method = RequestMethod.POST)
|
|
public ObjEnvelop registerPatientAndLogin(String name, String mobile, String idcard, String ssc, String pw,String client_id,String login_type)throws Exception{
|
|
|
|
|
|
public ObjEnvelop registerPatientAndLogin(String name, String mobile, String idcard, String ssc, String pw,String client_id,String login_type,String captcha,String openid)throws Exception{
|
|
|
|
|
|
if (StringUtils.isEmpty(client_id)) {
|
|
if (StringUtils.isEmpty(client_id)) {
|
|
throw new InvalidRequestException("client_id is null");
|
|
throw new InvalidRequestException("client_id is null");
|
|
}
|
|
}
|
|
|
|
|
|
|
|
if (wlyyRedisVerifyCodeService.verification(client_id, mobile, captcha)) {
|
|
|
|
//验证码正确
|
|
|
|
} else {
|
|
|
|
return ObjEnvelop.getError("验证码错误!");
|
|
|
|
}
|
|
|
|
|
|
try {
|
|
try {
|
|
|
|
|
|
Map<String,Object> rs = registerService.registerPatient(name,mobile,idcard,ssc,pw);
|
|
Map<String,Object> rs = registerService.registerPatient(name,mobile,idcard,ssc,pw);
|
|
@ -1274,7 +1280,7 @@ public class WlyyLoginEndpoint extends AbstractEndpoint {
|
|
return ObjEnvelop.getSuccess("success",wlyyUserSimple);
|
|
return ObjEnvelop.getSuccess("success",wlyyUserSimple);
|
|
|
|
|
|
}catch (Exception e){
|
|
}catch (Exception e){
|
|
logger.error(e);
|
|
|
|
|
|
e.printStackTrace();
|
|
}
|
|
}
|
|
return ObjEnvelop.getError("登录失败!");
|
|
return ObjEnvelop.getError("登录失败!");
|
|
}
|
|
}
|