Commit af264d7a by 李小龙 Committed by huangjy

fix:平台用户邮箱校验

parent ad18f3cb
...@@ -227,7 +227,7 @@ public class PlatUserServiceImpl extends ServiceImpl<PlatUserMapper, PlatUser> ...@@ -227,7 +227,7 @@ public class PlatUserServiceImpl extends ServiceImpl<PlatUserMapper, PlatUser>
.or() .or()
.eq(PlatUser::getMobile, dto.getMobile()) .eq(PlatUser::getMobile, dto.getMobile())
.or() .or()
.eq(PlatUser::getEmail,dto.getEmail()) .eq(StringUtils.isNotBlank(dto.getEmail()),PlatUser::getEmail,dto.getEmail())
) )
); );
...@@ -239,7 +239,7 @@ public class PlatUserServiceImpl extends ServiceImpl<PlatUserMapper, PlatUser> ...@@ -239,7 +239,7 @@ public class PlatUserServiceImpl extends ServiceImpl<PlatUserMapper, PlatUser>
if (e.getMobile().equals(dto.getMobile()) && !e.getId().equals(dto.getId())) { if (e.getMobile().equals(dto.getMobile()) && !e.getId().equals(dto.getId())) {
throw new BusinessException(CodeMessageEnum.SYSTEM_ERROR_USER_MOBILE_DUPLICATE); throw new BusinessException(CodeMessageEnum.SYSTEM_ERROR_USER_MOBILE_DUPLICATE);
} }
if (e.getEmail().equals(dto.getEmail()) && !e.getId().equals(dto.getId())) { if (StringUtils.isNotBlank(dto.getEmail()) && e.getEmail().equals(dto.getEmail()) && !e.getId().equals(dto.getId())) {
throw new BusinessException(CodeMessageEnum.SYSTEM_ERROR_USER_MAIL_DUPLICATE); throw new BusinessException(CodeMessageEnum.SYSTEM_ERROR_USER_MAIL_DUPLICATE);
} }
}); });
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or sign in to comment