diff --git a/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/service/impl/BuildingServiceImpl.java b/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/service/impl/BuildingServiceImpl.java index d178eb7540..4649e18546 100644 --- a/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/service/impl/BuildingServiceImpl.java +++ b/epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/service/impl/BuildingServiceImpl.java @@ -297,32 +297,6 @@ public class BuildingServiceImpl implements BuildingService { return result; } result.addAll(customerGridList.stream().map(m -> m.getId()).collect(Collectors.toList())); - List gridList = customerGridList.stream().map(item -> { - BuildingTreeLevelDTO buildingTreeLevelDTO = new BuildingTreeLevelDTO(); - buildingTreeLevelDTO.setId(item.getId()); - buildingTreeLevelDTO.setLabel(item.getGridName()); - buildingTreeLevelDTO.setLevel("grid"); - buildingTreeLevelDTO.setPId(item.getPid()); - buildingTreeLevelDTO.setLongitude(item.getLongitude()); - buildingTreeLevelDTO.setLatitude(item.getLatitude()); - buildingTreeLevelDTO.setChildren(new ArrayList<>()); - //当前网格下有几个小区 - buildingTreeLevelDTO.setShowNum(StrConstant.EPMETY_STR); - return buildingTreeLevelDTO; - }).collect(Collectors.toList()); - - - //3.获取网格下的所有小区 - List gridIdList = customerGridList.stream().map(BaseEpmetEntity::getId).collect(Collectors.toList()); - LambdaQueryWrapper queryWrapper = new QueryWrapper().lambda() - .in(IcNeighborHoodEntity::getGridId, gridIdList) - .orderByAsc(IcNeighborHoodEntity::getCreatedTime); - List icNeighborHoodList = icNeighborHoodDao.selectList(queryWrapper); - if(CollectionUtils.isEmpty(icNeighborHoodList)){ - agencyList.addAll(gridList); - return result; - } - result.addAll(icNeighborHoodList.stream().map(m -> m.getId()).collect(Collectors.toList())); return result; }