From 236d4b566be5406c7b6c0e9a6757f0d0b081d074 Mon Sep 17 00:00:00 2001 From: tangqian Date: Thu, 1 Jun 2023 12:02:45 +0800 Subject: [PATCH] =?UTF-8?q?fix:=20=E4=BF=AE=E6=94=B9=E9=83=A8=E9=97=A8?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../member/service/promoter/PromoterServiceImpl.java | 7 ++++--- 1 file changed, 4 insertions(+), 3 deletions(-) diff --git a/yudao-module-member/yudao-module-member-biz/src/main/java/cn/iocoder/yudao/module/member/service/promoter/PromoterServiceImpl.java b/yudao-module-member/yudao-module-member-biz/src/main/java/cn/iocoder/yudao/module/member/service/promoter/PromoterServiceImpl.java index 78c8b8ac1..26078984b 100644 --- a/yudao-module-member/yudao-module-member-biz/src/main/java/cn/iocoder/yudao/module/member/service/promoter/PromoterServiceImpl.java +++ b/yudao-module-member/yudao-module-member-biz/src/main/java/cn/iocoder/yudao/module/member/service/promoter/PromoterServiceImpl.java @@ -181,14 +181,15 @@ public class PromoterServiceImpl implements PromoterService { if (CollUtil.isEmpty(importUsers)) { throw exception(PROMOTER_IMPORT_LIST_IS_EMPTY); } + PromoterImportRespVO respVO = PromoterImportRespVO.builder().createUsernames(new ArrayList<>()) + .updateUsernames(new ArrayList<>()).failureUsernames(new LinkedHashMap<>()).build(); Set collect = importUsers.stream().map(PromoterImportExcelVO::getMobile).collect(Collectors.toSet()); List list = memberUserService.getByMobileList(collect); if (!CollectionUtils.isEmpty(list)) { List collect1 = list.stream().map(MemberUserDO::getMobile).collect(Collectors.toList()); - throw new ServiceException(200, "电话号码:" + collect1 + "重复"); + respVO.getFailureUsernames().put("电话号码:" + collect1, "重复"); } - PromoterImportRespVO respVO = PromoterImportRespVO.builder().createUsernames(new ArrayList<>()) - .updateUsernames(new ArrayList<>()).failureUsernames(new LinkedHashMap<>()).build(); + List deptRespDTOList = deptApi.getDeptList(); Map nameList = deptRespDTOList.stream().collect(toMap(DeptRespDTO::getParentOrganizationName, value -> value, (value1, value2) -> value1)); importUsers.forEach(importUser -> {