diff --git a/src/main/java/com/xkrs/controller/SysUserController.java b/src/main/java/com/xkrs/controller/SysUserController.java index e39528d..0822bbd 100644 --- a/src/main/java/com/xkrs/controller/SysUserController.java +++ b/src/main/java/com/xkrs/controller/SysUserController.java @@ -312,7 +312,7 @@ public class SysUserController { * 发送验证码 */ @GetMapping("/verificationCode") - public String verificationCode(@RequestParam("phone") String phone, @RequestParam(value = "agentOrgId", required = false) String agentOrgId) throws Exception { + public String verificationCode(@RequestParam("phone") String phone) throws Exception { String optCode = String.valueOf(RandomUtil.returnCode()); redisService.set(phone, optCode, 10, TimeUnit.MINUTES); SendSmsResponse response = AliYunSmsUtils.sendCode(phone, optCode); @@ -324,7 +324,6 @@ public class SysUserController { */ @GetMapping("/verificationCodeUpdate") public String verificationCodeUpdate(@RequestParam("phone") String phone) throws Exception { - Specification specification = (root, criteriaQuery, criteriaBuilder) -> { //查询条件集合 List predicateList = new ArrayList<>(); @@ -336,7 +335,6 @@ public class SysUserController { if (sysUserEntityList.size() == 0) { return outputEncapsulationObject(PromptMessageEnum.DATA_NONE, "手机号错误,请使用您注册的手机号", locale); } - SysUserEntity sysUserEntity = sysUserEntityList.get(0); String optCode = String.valueOf(RandomUtil.returnCode()); redisService.set(phone, optCode, 10, TimeUnit.MINUTES); SendSmsResponse response = AliYunSmsUtils.sendCode(phone, optCode); @@ -348,11 +346,11 @@ public class SysUserController { */ @GetMapping("/getVerificationCode") public String getVerificationCode(@RequestParam("phone") String phone, @RequestParam("verificationCode") String verificationCode) { - String o = (String) redisService.get(phone); - if ("".equals(o) || o == null) { + String code = (String) redisService.get(phone); + if (TextUtils.isEmpty(code)) { return outputEncapsulationObject(PromptMessageEnum.DATA_WRONG, "请先发送验证码!", locale); } - if (!redisService.get(phone).equals(verificationCode)) { + if (!code.equals(verificationCode)) { return outputEncapsulationObject(PromptMessageEnum.DATA_WRONG, "验证码错误,请重新输入!", locale); } return outputEncapsulationObject(PromptMessageEnum.SUCCESS, "true", locale); diff --git a/src/main/java/com/xkrs/model/qo/SysUserQo.java b/src/main/java/com/xkrs/model/qo/SysUserQo.java index c05cc99..c743bf4 100644 --- a/src/main/java/com/xkrs/model/qo/SysUserQo.java +++ b/src/main/java/com/xkrs/model/qo/SysUserQo.java @@ -53,11 +53,6 @@ public class SysUserQo { private String accountType; - /** - * 代理组织ID - */ - private Long agentOrgId; - public SysUserQo() { } @@ -165,11 +160,4 @@ public class SysUserQo { this.accountType = accountType; } - public Long getAgentOrgId() { - return agentOrgId; - } - - public void setAgentOrgId(Long agentOrgId) { - this.agentOrgId = agentOrgId; - } }