Browse Source

楼栋基本信息详情

dev
HAHA 3 years ago
parent
commit
d6052e66c0
  1. 17
      epmet-module/open-data-worker/open-data-worker-client/src/main/java/com/epmet/opendata/dto/form/CaLoudongDetailsFormDTO.java
  2. 140
      epmet-module/open-data-worker/open-data-worker-client/src/main/java/com/epmet/opendata/dto/result/CaLoudongDetailsResultDTO.java
  3. 17
      epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/controller/CaLoudongController.java
  4. 10
      epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/dao/CaLoudongDao.java
  5. 9
      epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/CaLoudongService.java
  6. 8
      epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/CaLoudongServiceImpl.java
  7. 38
      epmet-module/open-data-worker/open-data-worker-server/src/main/resources/mapper/CaLoudongDao.xml

17
epmet-module/open-data-worker/open-data-worker-client/src/main/java/com/epmet/opendata/dto/form/CaLoudongDetailsFormDTO.java

@ -0,0 +1,17 @@
package com.epmet.opendata.dto.form;
import lombok.Data;
import java.io.Serializable;
import java.math.BigInteger;
@Data
public class CaLoudongDetailsFormDTO implements Serializable {
private static final long serialVersionUID = -496629781476101758L;
/**
* 楼栋id
*/
private BigInteger buildingId;
}

140
epmet-module/open-data-worker/open-data-worker-client/src/main/java/com/epmet/opendata/dto/result/CaLoudongDetailsResultDTO.java

@ -0,0 +1,140 @@
package com.epmet.opendata.dto.result;
import java.io.Serializable;
import java.math.BigDecimal;
import java.util.Date;
public class CaLoudongDetailsResultDTO implements Serializable {
private static final long serialVersionUID = -8076699273641714744L;
/**
* 楼栋ID
*/
private Long buildingId;
/**
* 楼宇类型
*/
private String buildingType;
/**
* 网格ID
*/
private Long gridId;
/**
* 楼宇名称
*/
private String buildingName;
/**
* 用途分类
*/
private String buildingUse;
/**
* 楼宇状态
*/
private String buildingStatus;
/**
* 楼宇结构
*/
private String buildingStructure;
/**
* 使用现状
*/
private String buildingUseage;
/**
* 建筑时间
*/
private Date constructionTime;
/**
* 所处位置
*/
private String buildingAddr;
/**
* 小区单位名称
*/
private String communityName;
/**
* 楼栋长
*/
private String buildingLeader;
/**
* 楼层数
*/
private Integer layerCount;
/**
* 地下楼层数
*/
private Integer basementLayerCount;
/**
* 住宅开始层数
*/
private Integer houseBeginLayer;
/**
* 单元数
*/
private Integer unitCount;
/**
* 每层每单元户数
*/
private Integer layerRoomCount;
/**
* 总房屋数
*/
private Integer roomCount;
/**
* 电梯数量
*/
private String elevatorCount;
/**
* 建筑面积
*/
private String buildingArea;
/**
* 物业公司
*/
private String buildingPmc;
/**
* 介绍
*/
private String buildingDesc;
/**
* 标绘状态
*/
private String pointStatus;
/**
* 经度
*/
private BigDecimal longitude;
/**
* 纬度
*/
private BigDecimal latitude;
/**
* 小区主键
*/
private String communityId;
}

17
epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/controller/CaLoudongController.java

@ -12,7 +12,9 @@ import com.epmet.commons.tools.validator.group.AddGroup;
import com.epmet.commons.tools.validator.group.DefaultGroup;
import com.epmet.commons.tools.validator.group.UpdateGroup;
import com.epmet.opendata.dto.CaLoudongDTO;
import com.epmet.opendata.dto.form.CaLoudongDetailsFormDTO;
import com.epmet.opendata.dto.form.CaLoudongFormDTO;
import com.epmet.opendata.dto.result.CaLoudongDetailsResultDTO;
import com.epmet.opendata.dto.result.CaLoudongResultDTO;
import com.epmet.opendata.excel.CaLoudongExcel;
import com.epmet.opendata.service.CaLoudongService;
@ -96,4 +98,19 @@ public class CaLoudongController {
return new Result<PageData<CaLoudongResultDTO>>().ok(data);
}
/**
* 楼栋基本信息详情
*
* @param dto
* @param tokenDto
* @return com.epmet.commons.tools.utils.Result
* @author LZN
* @date 2022/6/1 9:37
*/
@PostMapping("getDetails")
public Result getLouDongDetails(@RequestBody CaLoudongDetailsFormDTO dto, @LoginUser TokenDto tokenDto) {
CaLoudongDetailsResultDTO result = caLoudongService.getLouDongDetails(dto);
return new Result().ok(result);
}
}

10
epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/dao/CaLoudongDao.java

@ -4,11 +4,13 @@ package com.epmet.opendata.dao;
import com.epmet.commons.mybatis.dao.BaseDao;
import com.epmet.dto.result.VolunteerPolyListResultDTO;
import com.epmet.opendata.dto.CaLoudongDTO;
import com.epmet.opendata.dto.result.CaLoudongDetailsResultDTO;
import com.epmet.opendata.dto.result.CaLoudongResultDTO;
import com.epmet.opendata.entity.CaLoudongEntity;
import org.apache.ibatis.annotations.Mapper;
import org.apache.ibatis.annotations.Param;
import java.math.BigInteger;
import java.util.List;
/**
@ -31,4 +33,12 @@ public interface CaLoudongDao extends BaseDao<CaLoudongEntity> {
* @date 2022/5/31 18:57
*/
List<CaLoudongResultDTO> getPage(@Param("communityName") String communityName);
/**
* 楼栋基本信息详情
*
* @param buildingId
* @return
*/
CaLoudongDetailsResultDTO getLouDongDetails(@Param("buildingId") BigInteger buildingId);
}

9
epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/CaLoudongService.java

@ -4,7 +4,9 @@ package com.epmet.opendata.service;
import com.epmet.commons.mybatis.service.BaseService;
import com.epmet.commons.tools.page.PageData;
import com.epmet.opendata.dto.CaLoudongDTO;
import com.epmet.opendata.dto.form.CaLoudongDetailsFormDTO;
import com.epmet.opendata.dto.form.CaLoudongFormDTO;
import com.epmet.opendata.dto.result.CaLoudongDetailsResultDTO;
import com.epmet.opendata.dto.result.CaLoudongResultDTO;
import com.epmet.opendata.entity.CaLoudongEntity;
@ -90,4 +92,11 @@ public interface CaLoudongService extends BaseService<CaLoudongEntity> {
*/
PageData<CaLoudongResultDTO> getPage(CaLoudongFormDTO dto);
/**
* 楼栋基本信息详情
*
* @param dto
* @return
*/
CaLoudongDetailsResultDTO getLouDongDetails(CaLoudongDetailsFormDTO dto);
}

8
epmet-module/open-data-worker/open-data-worker-server/src/main/java/com/epmet/opendata/service/impl/CaLoudongServiceImpl.java

@ -7,7 +7,9 @@ import com.epmet.commons.tools.page.PageData;
import com.epmet.commons.tools.utils.ConvertUtils;
import com.epmet.opendata.dao.CaLoudongDao;
import com.epmet.opendata.dto.CaLoudongDTO;
import com.epmet.opendata.dto.form.CaLoudongDetailsFormDTO;
import com.epmet.opendata.dto.form.CaLoudongFormDTO;
import com.epmet.opendata.dto.result.CaLoudongDetailsResultDTO;
import com.epmet.opendata.dto.result.CaLoudongResultDTO;
import com.epmet.opendata.entity.CaLoudongEntity;
import com.epmet.opendata.redis.CaLoudongRedis;
@ -103,5 +105,11 @@ public class CaLoudongServiceImpl extends BaseServiceImpl<CaLoudongDao, CaLoudon
return new PageData<>(result, info.getTotal());
}
@Override
public CaLoudongDetailsResultDTO getLouDongDetails(CaLoudongDetailsFormDTO dto) {
CaLoudongDetailsResultDTO result = baseDao.getLouDongDetails(dto.getBuildingId());
return result;
}
}

38
epmet-module/open-data-worker/open-data-worker-server/src/main/resources/mapper/CaLoudongDao.xml

@ -89,6 +89,44 @@
</if>
</where>
</select>
<select id="getLouDongDetails" resultType="com.epmet.opendata.dto.result.CaLoudongDetailsResultDTO">
SELECT
building_id,
building_type,
grid_id,
building_name,
building_use,
building_status,
building_structure,
building_useage,
construction_time,
building_addr,
community_name,
building_leader,
layer_count,
basement_layer_count,
house_begin_layer,
unit_count,
layer_room_count,
room_count,
elevator_count,
building_area,
building_pmc,
building_desc,
point_status,
longitude,
latitude,
plat_code,
community_id
FROM
ca_loudong
<where>
delete_flag = 'normal'
<if test="buildingId != null and buildingId != ''">
AND building_id = #{buildingId}
</if>
</where>
</select>
</mapper>
Loading…
Cancel
Save