From cebc05d132cb623e5c7ed51eaf624870f98a94be Mon Sep 17 00:00:00 2001 From: xupei Date: Tue, 27 Aug 2024 11:32:47 +0800 Subject: [PATCH] =?UTF-8?q?BUGFIX=EF=BC=9A=E7=AE=A1=E7=90=86=E5=91=98?= =?UTF-8?q?=E7=B3=BB=E7=BB=9F=20=E6=B7=BB=E5=8A=A0=E6=96=B0=E7=94=A8?= =?UTF-8?q?=E6=88=B7=E9=82=AE=E7=AE=B1=E6=A0=A1=E9=AA=8C=EF=BC=8C=E7=9B=B8?= =?UTF-8?q?=E5=90=8C=E7=9A=84=E9=82=AE=E7=AE=B1=E5=8F=AA=E8=83=BD=E5=88=9B?= =?UTF-8?q?=E5=BB=BA=E4=B8=80=E4=B8=AA=E8=B4=A6=E5=8F=B7?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../ai/da/service/impl/ConvenientInquiryServiceImpl.java | 8 ++++++++ 1 file changed, 8 insertions(+) diff --git a/src/main/java/com/ai/da/service/impl/ConvenientInquiryServiceImpl.java b/src/main/java/com/ai/da/service/impl/ConvenientInquiryServiceImpl.java index b664ed21..43c99f5a 100644 --- a/src/main/java/com/ai/da/service/impl/ConvenientInquiryServiceImpl.java +++ b/src/main/java/com/ai/da/service/impl/ConvenientInquiryServiceImpl.java @@ -437,8 +437,16 @@ public class ConvenientInquiryServiceImpl extends ServiceImpl queryWrapper = new QueryWrapper<>(); + queryWrapper.eq("user_email", account.getUserEmail()); + + Account existsAccount = accountMapper.selectOne(queryWrapper); + if (!Objects.isNull(existsAccount)){ + throw new BusinessException("The email address already exists. One email address can only register one AiDA account"); + } // 添加正式用户 + assert accountAddDTO != null; if (Objects.isNull(accountAddDTO.getSystemUser())) { throw new BusinessException("you have to choose user type"); } else {