diff --git a/epmet-user/epmet-user-server/src/main/java/com/epmet/service/impl/IcResiUserServiceImpl.java b/epmet-user/epmet-user-server/src/main/java/com/epmet/service/impl/IcResiUserServiceImpl.java index d87b068e73..1d9b9a8a25 100644 --- a/epmet-user/epmet-user-server/src/main/java/com/epmet/service/impl/IcResiUserServiceImpl.java +++ b/epmet-user/epmet-user-server/src/main/java/com/epmet/service/impl/IcResiUserServiceImpl.java @@ -4046,13 +4046,13 @@ public class IcResiUserServiceImpl extends BaseServiceImpl> dictResult = epmetAdminOpenFeignClient.dictList(dictFormDTO); - if (!dictResult.success() || CollectionUtils.isEmpty(dictResult.getData())) { - throw new EpmetException(EpmetErrorCode.EPMET_COMMON_OPERATION_FAIL.getCode(), "学历字典获取失败", "学历字典获取失败"); - } - Map educationMap = dictResult.getData().stream().collect(Collectors.toMap(DictListResultDTO::getValue, DictListResultDTO::getLabel)); + // DictListFormDTO dictFormDTO = new DictListFormDTO(); + // dictFormDTO.setDictType(DictTypeEnum.EDUCATION.getCode()); + // Result> dictResult = epmetAdminOpenFeignClient.dictList(dictFormDTO); + // if (!dictResult.success() || CollectionUtils.isEmpty(dictResult.getData())) { + // throw new EpmetException(EpmetErrorCode.EPMET_COMMON_OPERATION_FAIL.getCode(), "学历字典获取失败", "学历字典获取失败"); + // } + // Map educationMap = dictResult.getData().stream().collect(Collectors.toMap(DictListResultDTO::getValue, DictListResultDTO::getLabel)); if (StringUtils.isBlank(orgId)) { orgId = CustomerStaffRedis.getStaffInfo(customerId, staffId).getAgencyId(); @@ -4073,7 +4073,7 @@ public class IcResiUserServiceImpl extends BaseServiceImpl { // 学历名称 - resi.setEducationName(educationMap.get(resi.getEducationCode())); + // resi.setEducationName(educationMap.get(resi.getEducationCode())); GridInfoCache gridInfoCache = CustomerOrgRedis.getGridInfo(resi.getGridId()); if (null != gridInfoCache) { resi.setGridName(gridInfoCache.getGridNamePath()); @@ -4106,13 +4106,13 @@ public class IcResiUserServiceImpl extends BaseServiceImpl> dictResult = epmetAdminOpenFeignClient.dictList(dictFormDTO); if (!dictResult.success() || CollectionUtils.isEmpty(dictResult.getData())) { throw new EpmetException(EpmetErrorCode.EPMET_COMMON_OPERATION_FAIL.getCode(), "学历字典获取失败", "学历字典获取失败"); } - Map educationMap = dictResult.getData().stream().collect(Collectors.toMap(DictListResultDTO::getValue, DictListResultDTO::getLabel)); + Map educationMap = dictResult.getData().stream().collect(Collectors.toMap(DictListResultDTO::getValue, DictListResultDTO::getLabel));*/ if (StringUtils.isBlank(orgId)) { orgId = CustomerStaffRedis.getStaffInfo(customerId, staffId).getAgencyId(); @@ -4124,12 +4124,12 @@ public class IcResiUserServiceImpl extends BaseServiceImpl list = baseDao.selectPortrayalResiList(customerId, orgId, orgType,orgIdPath,codeType, code); - if(CollectionUtils.isNotEmpty(list)){ - list.forEach(resi -> { - // 学历名称 - resi.setEducationName(educationMap.get(resi.getEducationCode())); - }); - } + // if(CollectionUtils.isNotEmpty(list)){ + // list.forEach(resi -> { + // // 学历名称 + // resi.setEducationName(educationMap.get(resi.getEducationCode())); + // }); + // } PageInfo pageInfo = new PageInfo<>(list); return new PageData<>(list, pageInfo.getTotal(), pageSize); } diff --git a/epmet-user/epmet-user-server/src/main/resources/mapper/IcResiUserDao.xml b/epmet-user/epmet-user-server/src/main/resources/mapper/IcResiUserDao.xml index 5db97e1f5e..b5e5b604d2 100644 --- a/epmet-user/epmet-user-server/src/main/resources/mapper/IcResiUserDao.xml +++ b/epmet-user/epmet-user-server/src/main/resources/mapper/IcResiUserDao.xml @@ -1673,6 +1673,18 @@ ( CASE WHEN u.GENDER = '1' THEN '男' WHEN u.GENDER = '2' THEN '女' ELSE '未知' END ) AS genderName, YEAR (NOW())- SUBSTR( u.BIRTHDAY, 1, 4 ) AS age, u.CULTURE AS educationCode, + ( + case when u.CULTURE='0' then '小学及文盲' + when u.CULTURE='1' then '初中' + when u.CULTURE='2' then '高中' + when u.CULTURE='3' then '大专' + when u.CULTURE='4' then '本科' + when u.CULTURE='5' then '硕士' + when u.CULTURE='6' then '博士' + when u.CULTURE='7' then '中专' + else '' + end + )as educationName, '' AS educationName, IFNULL(u.CULTURE,'')AS educationCode, u.BIRTHDAY AS birthday