去掉校验验证码

This commit is contained in:
liubozhi 2025-03-26 14:56:09 +08:00
parent 546f2721d2
commit aaac9cccd9
4 changed files with 17 additions and 14 deletions

View File

@ -128,13 +128,14 @@ public class ShopUserController {
if (shopUserDTO.getPhone().contains(Constant.ASTERISK)) {
shopUserDTO.setPhone(dbShopUser.getPhone());
}
//TODO 去掉验证码校验
// 如果修改了手机号码就需要校验验证码
if (!StrUtil.equals(dbShopUser.getPhone(), shopUserDTO.getPhone())) {
if (StrUtil.isBlank(shopUserDTO.getValidCode())) {
throw new LuckException("修改了手机号,请输入验证码校验");
}
checkCode(shopUserDTO);
}
// if (!StrUtil.equals(dbShopUser.getPhone(), shopUserDTO.getPhone())) {
// if (StrUtil.isBlank(shopUserDTO.getValidCode())) {
// throw new LuckException("修改了手机号,请输入验证码校验");
// }
// checkCode(shopUserDTO);
// }
shopUserDTO.setShopId(dbShopUser.getShopId());
ServerResponseEntity<AuthAccountVO> authAccountEntity = accountFeignClient.getByUserIdAndType(dbShopUser.getShopUserId(), SysTypeEnum.MULTISHOP.value());
if (!authAccountEntity.isSuccess()) {
@ -180,9 +181,10 @@ public class ShopUserController {
if (StrUtil.isNotBlank(phone)) {
ServerResponseEntity<Boolean> sendNotifyResponse = notifyFeignClient.checkValidCode(phone, shopUserDTO.getValidCode(), SendTypeEnum.VALID);
Boolean data = sendNotifyResponse.getData();
if (Objects.equals(sendNotifyResponse.getCode(), ResponseEnum.OK.value()) && Objects.nonNull(data) && !data) {
throw new LuckException("验证码有误或已过期!");
}
//TODO 去掉验证码校验
// if (Objects.equals(sendNotifyResponse.getCode(), ResponseEnum.OK.value()) && Objects.nonNull(data) && !data) {
// throw new LuckException("验证码有误或已过期!");
// }
}
//邮箱验证码
}

View File

@ -546,9 +546,10 @@ public class ShopDetailServiceImpl implements ShopDetailService {
ShopUserRegisterDTO shopUserRegisterInfo = shopCreateInfoDTO.getShopUserRegisterInfo();
ServerResponseEntity<Boolean> sendNotifyResponse = notifyFeignClient.checkValidCode(shopUserRegisterInfo.getMobile(), shopUserRegisterInfo.getValidCode(), SendTypeEnum.VALID);
Boolean data = sendNotifyResponse.getData();
if (Objects.equals(sendNotifyResponse.getCode(), ResponseEnum.OK.value()) && Objects.nonNull(data) && !data) {
throw new LuckException("验证码有误或已过期!");
}
//TODO 去掉验证码校验
// if (Objects.equals(sendNotifyResponse.getCode(), ResponseEnum.OK.value()) && Objects.nonNull(data) && !data) {
// throw new LuckException("验证码有误或已过期!");
// }
// 2保存店铺基本信息
Date now = new Date();
ShopDetailDTO shopDetailDTO = shopCreateInfoDTO.getShopDetail();

View File

@ -104,7 +104,7 @@ public class LoginController {
&& flag) {
return ServerResponseEntity.showFailMsg("tempUid is blank");
}
// //校验验证码
// //TODO 校验验证码
// ServerResponseEntity<Boolean> validCodeResponse = notifyFeignClient.checkValidCode(loginCode.getMobile(), loginCode.getValidCode(), SendTypeEnum.LOGIN);
// if (!validCodeResponse.isSuccess() || !validCodeResponse.getData()) {
// return ServerResponseEntity.fail(ResponseEnum.VERIFICATION_CODE_ERROR);

View File

@ -99,7 +99,7 @@ public class ServerResponseEntity<T> implements Serializable {
public ServerResponseEntity() {
// 版本号
this.version = "mall4j.v240108";
this.version = "tmerclub.v250326";
}
public boolean isSuccess() {