|
@ -237,6 +237,19 @@ public class AgencyServiceImpl implements AgencyService { |
|
|
agencysResultDTO = ConvertUtils.sourceToTarget(entity, AgencysResultDTO.class); |
|
|
agencysResultDTO = ConvertUtils.sourceToTarget(entity, AgencysResultDTO.class); |
|
|
agencysResultDTO.setAgencyId(entity.getId()); |
|
|
agencysResultDTO.setAgencyId(entity.getId()); |
|
|
agencysResultDTO.setAgencyName(entity.getOrganizationName()); |
|
|
agencysResultDTO.setAgencyName(entity.getOrganizationName()); |
|
|
|
|
|
//2021.5.26 sun 添加当前组织对应客户的根组织级别返参 start
|
|
|
|
|
|
if (null != entity) { |
|
|
|
|
|
if (null == entity.getPids() || "".equals(entity.getPids())) { |
|
|
|
|
|
agencysResultDTO.setRootlevel(entity.getLevel()); |
|
|
|
|
|
} else { |
|
|
|
|
|
String id = Arrays.asList(entity.getPids().split(":")).get(0); |
|
|
|
|
|
CustomerAgencyEntity rootEntity = customerAgencyDao.selectById(id); |
|
|
|
|
|
if (null != rootEntity) { |
|
|
|
|
|
agencysResultDTO.setRootlevel(rootEntity.getLevel()); |
|
|
|
|
|
} |
|
|
|
|
|
} |
|
|
|
|
|
} |
|
|
|
|
|
//2021.5.26 sun 添加当前组织对应客户的根组织级别返参 end
|
|
|
//2:查询本机关的所有上级机关,按自上而下层级顺序
|
|
|
//2:查询本机关的所有上级机关,按自上而下层级顺序
|
|
|
if (null == entity.getPids()) { |
|
|
if (null == entity.getPids()) { |
|
|
agencysResultDTO.setParentList(parentList); |
|
|
agencysResultDTO.setParentList(parentList); |
|
|