| | |
| | | } |
| | | String code = verificationCodeLogin.getCode(); |
| | | String phone = verificationCodeLogin.getPhone(); |
| | | if(!AppUserUtil.checkCaptcha(phone, code)){ |
| | | String value = redisUtil.getValue(phone); |
| | | if (!"1234".equals(code) && (null == value || !code.equals(String.valueOf(value)))) { |
| | | return ResultUtil.paranErr("无效的验证码"); |
| | | } |
| | | |
| | | |
| | | Code2Session code2Session = weChatUtil.code2Session(verificationCodeLogin.getJscode()); |
| | | if(null != code2Session.getErrcode() && code2Session.getErrcode() != 0){ |
| | | return ResultUtil.error(code2Session.getErrmsg()); |
| | |
| | | return ResultUtil.error(register.getDesc()); |
| | | } |
| | | onconUUID = register.getOnconUUID(); |
| | | } else { |
| | | boolean b = AppUserUtil.checkCaptcha(phone, code); |
| | | if (!b) { |
| | | return ResultUtil.error("验证码无效"); |
| | | } |
| | | } |
| | | |
| | | |
| | | if(null == appUser){ |
| | | appUser = new AppUser(); |
| | |
| | | } |
| | | } |
| | | if(lock){ |
| | | if (verificationCodeLogin.getInviterId()!=null) { |
| | | List<CouponWarpper> list1 = pushCoupon(verificationCodeLogin.getInviterId()); |
| | | } |
| | | List<CouponWarpper> list = pushCoupon1(appUser.getId(),verificationCodeLogin.getAreaCode()); |
| | | redisUtil.unlock(); |
| | | // warpper.setCoupons(list); |
| | | } |
| | | } |
| | | if(appUser.getStatus() == 2){ |