From f9c24ba3d5eba45afef222dcd72b6383893efc76 Mon Sep 17 00:00:00 2001 From: liukangdong <898885815@qq.com> Date: 星期二, 07 一月 2025 17:23:32 +0800 Subject: [PATCH] Merge branch 'master' of http://139.186.142.91:10010/r/productDev/dmvisit --- server/system_service/src/main/java/com/doumee/service/system/impl/SystemLoginServiceImpl.java | 26 +++++++++++++------------- 1 files changed, 13 insertions(+), 13 deletions(-) diff --git a/server/system_service/src/main/java/com/doumee/service/system/impl/SystemLoginServiceImpl.java b/server/system_service/src/main/java/com/doumee/service/system/impl/SystemLoginServiceImpl.java index 527883a..7a2a9fa 100644 --- a/server/system_service/src/main/java/com/doumee/service/system/impl/SystemLoginServiceImpl.java +++ b/server/system_service/src/main/java/com/doumee/service/system/impl/SystemLoginServiceImpl.java @@ -403,19 +403,19 @@ throw new BusinessException(ResponseStatus.ACCOUNT_INCORRECT); } //娉ㄥ唽鍙告満 - if((Constants.equalsInteger(user.getType(),Constants.ZERO) + if(!((Constants.equalsInteger(user.getType(),Constants.ZERO) ||Constants.equalsInteger(user.getType(),Constants.TWO)) - && Objects.nonNull(user.getMemberId())){ - if(Constants.equalsInteger(user.getType(),Constants.TWO)){ - if(Objects.isNull(user.getCompanyId())){ - throw new BusinessException(ResponseStatus.NO_ALLOW_LOGIN); - } - Company company = companyMapper.selectById(user.getCompanyId()); - if(Objects.isNull(company) || Constants.equalsInteger(company.getType(),Constants.ONE)){ - throw new BusinessException(ResponseStatus.NO_ALLOW_LOGIN); - } - } - }else{ + && Objects.nonNull(user.getMemberId()))){ +// if(Constants.equalsInteger(user.getType(),Constants.TWO)){ +// if(Objects.isNull(user.getCompanyId())){ +// throw new BusinessException(ResponseStatus.NO_ALLOW_LOGIN); +// } +// Company company = companyMapper.selectById(user.getCompanyId()); +// if(Objects.isNull(company) || Constants.equalsInteger(company.getType(),Constants.ONE)){ +// throw new BusinessException(ResponseStatus.NO_ALLOW_LOGIN); +// } +// } +// }else{ throw new BusinessException(ResponseStatus.NO_ALLOW_LOGIN); } if(StringUtils.isNotBlank(password)){ @@ -473,7 +473,7 @@ if (systemUser == null) { systemUser = autoRegisterUser(Constants.memberType.driver,param.getPhone(),param.getOpenid(),true); }else{ - if(!Constants.equalsInteger(systemUser.getType(),Constants.memberType.driver)){ + if(!(Constants.equalsInteger(systemUser.getType(),Constants.memberType.driver)||Constants.equalsInteger(systemUser.getType(),Constants.memberType.internal))){ throw new BusinessException(ResponseStatus.NOT_ALLOWED.getCode(),"瀵逛笉璧凤紝璇蜂娇鐢ㄦ纭殑鍙告満璐﹀彿鐧婚檰锛�"); } } -- Gitblit v1.9.3