Browse Source

小区 楼宇 房屋 排序

小区创建时间
楼宇  漏洞名称
房屋 单元-门牌号
master
jianjun 4 years ago
parent
commit
82f7e51d7b
  1. 7
      epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/controller/HouseController.java
  2. 18
      epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/service/impl/BuildingServiceImpl.java
  3. 27
      epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/service/impl/HouseServiceImpl.java
  4. 8
      epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/service/impl/NeighborHoodServiceImpl.java
  5. 4
      epmet-module/gov-org/gov-org-server/src/main/resources/mapper/IcBuildingDao.xml
  6. 1
      epmet-module/gov-org/gov-org-server/src/main/resources/mapper/IcHouseDao.xml
  7. 3
      epmet-module/gov-org/gov-org-server/src/main/resources/mapper/IcNeighborHoodDao.xml

7
epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/controller/HouseController.java

@ -32,7 +32,6 @@ import com.epmet.dto.result.HouseInfoDTO;
import com.epmet.dto.result.IcNeighborHoodResultDTO;
import com.epmet.excel.IcHouseExcel;
import com.epmet.service.HouseService;
import com.epmet.service.NeighborHoodService;
import com.epmet.util.ExcelPoiUtils;
import lombok.extern.slf4j.Slf4j;
import org.springframework.beans.factory.annotation.Autowired;
@ -56,10 +55,6 @@ import java.util.stream.Collectors;
@RestController
@RequestMapping("house")
public class HouseController {
@Autowired
private NeighborHoodService neighborHoodService;
@Autowired
private HouseService houseService;
@ -173,4 +168,4 @@ public class HouseController {
Result<List<HouseInfoDTO>> queryListHouseInfo(@RequestBody Set<String> houseIds){
return new Result<List<HouseInfoDTO>>().ok(houseService.queryListHouseInfo(houseIds));
}
}
}

18
epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/service/impl/BuildingServiceImpl.java

@ -365,25 +365,9 @@ public class BuildingServiceImpl implements BuildingService {
private IPage<Map<String, Object>> searchBuilding(ListIcNeighborHoodFormDTO formDTO) {
IPage<IcBuildingEntity> page = new Page<IcBuildingEntity>(formDTO.getPageNo(),formDTO.getPageSize());
// IcNeighborHoodEntity neighbor = new IcNeighborHoodEntity();
// IcNeighborHoodEntity neighbor = ConvertUtils.sourceToTarget(formDTO, IcNeighborHoodEntity.class);
// QueryWrapper<IcNeighborHoodEntity> neighborHoodEntityQueryWrapper = new QueryWrapper<>();
// neighborHoodEntityQueryWrapper.lambda()
// .eq(!StringUtils.isEmpty(formDTO.getAgencyId()),IcNeighborHoodEntity::getAgencyId,formDTO.getAgencyId())
// .eq(!StringUtils.isEmpty(formDTO.getGridId()),IcNeighborHoodEntity::getId,formDTO.getGridId())
// .eq(!StringUtils.isEmpty(formDTO.getNeighborHoodId()),IcNeighborHoodEntity::getId,formDTO.getNeighborHoodId())
// .like(!StringUtils.isEmpty(formDTO.getNeighborHoodName()),IcNeighborHoodEntity::getNeighborHoodName,formDTO.getNeighborHoodName());
IcBuildingEntity building = ConvertUtils.sourceToTarget(formDTO, IcBuildingEntity.class);
building.setDelFlag("0");
// QueryWrapper<IcBuildingEntity> buildingEntityQueryWrapper = new QueryWrapper<>();
//
// buildingEntityQueryWrapper.lambda()
// .eq(!StringUtils.isEmpty(formDTO.getBuildingId()),IcBuildingEntity::getId,formDTO.getBuildingId())
// .like(!StringUtils.isEmpty(formDTO.getBuildingName()),IcBuildingEntity::getBuildingName,formDTO.getBuildingName());
// buildingEntityQueryWrapper.eq("a.DEL_FLAG","0");
IcHouseEntity house = ConvertUtils.sourceToTarget(formDTO, IcHouseEntity.class);
IPage<Map<String, Object>> mapIPage = icBuildingDao.searchBuildingByPage(page, building, house);
List<Map<String, Object>> records = mapIPage.getRecords();

27
epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/service/impl/HouseServiceImpl.java

@ -201,9 +201,7 @@ public class HouseServiceImpl implements HouseService {
//3.保存
icHouseService.insertBatch(houseEntityList);
/*if(!"".equals(str)){
return new Result().error(9999, str.append("不存在").toString());
}*/
return numList;
}
@ -252,28 +250,6 @@ public class HouseServiceImpl implements HouseService {
private IPage<Map<String, Object>> searchHouse(ListIcNeighborHoodFormDTO formDTO) {
IPage<IcHouseEntity> page = new Page<IcHouseEntity>(formDTO.getPageNo(),formDTO.getPageSize());
// QueryWrapper<IcNeighborHoodEntity> neighborHoodEntityQueryWrapper = new QueryWrapper<>();
// neighborHoodEntityQueryWrapper.lambda()
// .eq(!StringUtils.isEmpty(formDTO.getAgencyId()),IcNeighborHoodEntity::getAgencyId,formDTO.getAgencyId())
// .eq(!StringUtils.isEmpty(formDTO.getGridId()),IcNeighborHoodEntity::getId,formDTO.getGridId())
// .eq(!StringUtils.isEmpty(formDTO.getNeighborHoodId()),IcNeighborHoodEntity::getId,formDTO.getNeighborHoodId())
// .like(!StringUtils.isEmpty(formDTO.getNeighborHoodName()),IcNeighborHoodEntity::getNeighborHoodName,formDTO.getNeighborHoodName());
// IcNeighborHoodEntity neighbor = ConvertUtils.sourceToTarget(formDTO, IcNeighborHoodEntity.class);
// QueryWrapper<IcBuildingEntity> buildingEntityQueryWrapper = new QueryWrapper<>();
// buildingEntityQueryWrapper.lambda()
// .eq(!StringUtils.isEmpty(formDTO.getBuildingId()),IcBuildingEntity::getId,formDTO.getBuildingId())
// .like(!StringUtils.isEmpty(formDTO.getBuildingName()),IcBuildingEntity::getBuildingName,formDTO.getBuildingName());
// IcBuildingEntity building = ConvertUtils.sourceToTarget(formDTO, IcBuildingEntity.class);
// QueryWrapper<IcHouseEntity> houseEntityQueryWrapper = new QueryWrapper<>();
// houseEntityQueryWrapper.lambda()
// .eq(!StringUtils.isEmpty(formDTO.getOwnerName()),IcHouseEntity::getOwnerName,formDTO.getOwnerName())
// .like(!StringUtils.isEmpty(formDTO.getOwnerPhone()),IcHouseEntity::getOwnerPhone,formDTO.getOwnerPhone());
// houseEntityQueryWrapper.eq("a.DEL_FLAG","0");
IcHouseEntity house = ConvertUtils.sourceToTarget(formDTO, IcHouseEntity.class);
house.setDelFlag("0");
@ -281,7 +257,6 @@ public class HouseServiceImpl implements HouseService {
List<Map<String, Object>> records = mapIPage.getRecords();
records.forEach(item->{
item.put("houseType", HouseTypeEnums.getTypeValue(item.get("houseTypeKey")));
// item.put("rentFlag", HouseRentFlagEnums.getTypeValue(item.get("rentFlagKey") ));
item.put("purpose", HousePurposeEnums.getTypeValue(item.get("purposeKey")));
});
return mapIPage;

8
epmet-module/gov-org/gov-org-server/src/main/java/com/epmet/service/impl/NeighborHoodServiceImpl.java

@ -133,14 +133,6 @@ public class NeighborHoodServiceImpl implements NeighborHoodService {
IPage<IcNeighborHoodEntity> page = new Page<IcNeighborHoodEntity>(formDTO.getPageNo(),formDTO.getPageSize());
// QueryWrapper<IcNeighborHoodEntity> neighborHoodEntityQueryWrapper = new QueryWrapper<>();
// neighborHoodEntityQueryWrapper.lambda()
// .eq(!StringUtils.isEmpty(formDTO.getAgencyId()),IcNeighborHoodEntity::getAgencyId,formDTO.getAgencyId())
// .eq(!StringUtils.isEmpty(formDTO.getGridId()),IcNeighborHoodEntity::getId,formDTO.getGridId())
// .eq(!StringUtils.isEmpty(formDTO.getNeighborHoodId()),IcNeighborHoodEntity::getId,formDTO.getNeighborHoodId())
// .like(!StringUtils.isEmpty(formDTO.getNeighborHoodName()),IcNeighborHoodEntity::getNeighborHoodName,formDTO.getNeighborHoodName());
// neighborHoodEntityQueryWrapper.eq("a.DEL_FLAG","0");
IcNeighborHoodEntity neighbor = ConvertUtils.sourceToTarget(formDTO, IcNeighborHoodEntity.class);
IcHouseEntity house = ConvertUtils.sourceToTarget(formDTO, IcHouseEntity.class);
neighbor.setDelFlag("0");

4
epmet-module/gov-org/gov-org-server/src/main/resources/mapper/IcBuildingDao.xml

@ -94,7 +94,7 @@
AND a.DEL_FLAG = #{building.delFlag}
</if>
</where>
order by a.CREATED_TIME asc
order by a.BUILDING_NAME
</select>
<select id="searchAllBuilding" resultType="com.epmet.excel.IcBuildingExcel">
select
@ -333,4 +333,4 @@
</select>
</mapper>
</mapper>

1
epmet-module/gov-org/gov-org-server/src/main/resources/mapper/IcHouseDao.xml

@ -144,6 +144,7 @@
</if>
</where>
ORDER BY d.UNIT_NUM,a.DOOR_NAME
</select>
<select id="searchAllHouse" resultType="com.epmet.excel.IcHouseExcel">
select

3
epmet-module/gov-org/gov-org-server/src/main/resources/mapper/IcNeighborHoodDao.xml

@ -106,6 +106,7 @@
AND a.DEL_FLAG = #{neighbor.delFlag}
</if>
</where>
ORDER BY a.CREATED_TIME
</select>
<select id="searchAllNeighborhood" resultType="com.epmet.excel.IcNeighborHoodExcel">
select
@ -213,4 +214,4 @@
and a.id !=#{neighborId}
</if>
</select>
</mapper>
</mapper>

Loading…
Cancel
Save