Commit 0ff3f829 authored by 李腾威's avatar 李腾威

消防水源消防队伍改造

parent ac9da698
...@@ -47,7 +47,7 @@ public interface WaterResourceMapper extends BaseMapper<WaterResource> { ...@@ -47,7 +47,7 @@ public interface WaterResourceMapper extends BaseMapper<WaterResource> {
*/ */
Page<WaterResourceDto> getWaterResourcePageByParams(Page<WaterResourceDto> page, String name, String resourceType, Page<WaterResourceDto> getWaterResourcePageByParams(Page<WaterResourceDto> page, String name, String resourceType,
ArrayList<Long> belongBuildingId, Long belongFightingSystemId, ArrayList<Long> belongBuildingId, Long belongFightingSystemId,
Long sequenceNbr, String equipId,String bizOrgCode); Long sequenceNbr, String equipId,String bizOrgCode, String equipCateGoryCode);
Map<String, Object> getWaterTypeByBizOrgCode(String bizOrgCode); List<Map<String, Object>> getWaterTypeByBizOrgCode(String bizOrgCode);
} }
...@@ -134,6 +134,7 @@ ...@@ -134,6 +134,7 @@
select * from cb_water_resource where is_delete = 1 select * from cb_water_resource where is_delete = 1
<if test="sequenceNbr != null and sequenceNbr != ''">and sequence_nbr = #{sequenceNbr}</if> <if test="sequenceNbr != null and sequenceNbr != ''">and sequence_nbr = #{sequenceNbr}</if>
<if test="resourceType != null and resourceType != ''">and resource_type = #{resourceType}</if> <if test="resourceType != null and resourceType != ''">and resource_type = #{resourceType}</if>
<if test="equipCateGoryCode != null and equipCateGoryCode != ''">and equip_category_code = #{equipCateGoryCode}</if>
<if test="equipId != null and equipId != ''">and equip_id = #{equipId}</if> <if test="equipId != null and equipId != ''">and equip_id = #{equipId}</if>
<if test="name != null and name != ''">and name like concat('%', #{name}, '%')</if> <if test="name != null and name != ''">and name like concat('%', #{name}, '%')</if>
<if test="belongFightingSystemId != null"> <if test="belongFightingSystemId != null">
...@@ -152,15 +153,15 @@ ...@@ -152,15 +153,15 @@
</select> </select>
<select id="getWaterTypeByBizOrgCode" resultType="map"> <select id="getWaterTypeByBizOrgCode" resultType="map">
SELECT SELECT
equip_category_code, equip_category_code type,
COUNT(sequence_nbr) as num COUNT(sequence_nbr) as num
FROM FROM
cb_water_resource cb_water_resource
WHERE WHERE
is_delete = 0 is_delete = 1
<if test="bizOrgCode != null and bizOrgCode != ''">AND biz_org_code like concat( #{bizOrgCode}, '%')</if> <if test="bizOrgCode != null and bizOrgCode != ''">AND biz_org_code like concat( #{bizOrgCode}, '%')</if>
GROUP BY GROUP BY
equip_category_code equip_category_code
......
...@@ -465,14 +465,15 @@ public class WaterResourceController extends BaseController { ...@@ -465,14 +465,15 @@ public class WaterResourceController extends BaseController {
Long belongFightingSystemId, Long sequenceNbr, Long belongFightingSystemId, Long sequenceNbr,
String resourceType, String resourceType,
String classifyId, String classifyId,
String bizOrgCode) { String bizOrgCode,
String equipCateGoryCode) {
Page<WaterResourceDto> page = new Page<>(); Page<WaterResourceDto> page = new Page<>();
page.setCurrent(pageNum); page.setCurrent(pageNum);
page.setSize(pageSize); page.setSize(pageSize);
/*bug 2913 更换保存方式 存储到公共附件表 chenzhao 2021-10-18 start*/ /*bug 2913 更换保存方式 存储到公共附件表 chenzhao 2021-10-18 start*/
Page<WaterResourceDto> waterResourceDtoPage = waterResourceServiceImpl.queryForWaterResourcePage(page, name, resourceType, Page<WaterResourceDto> waterResourceDtoPage = waterResourceServiceImpl.queryForWaterResourcePage(page, name, resourceType,
belongBuildingId, belongFightingSystemId, sequenceNbr, classifyId,bizOrgCode); belongBuildingId, belongFightingSystemId, sequenceNbr, classifyId,bizOrgCode, equipCateGoryCode);
List<WaterResourceDto> records = waterResourceDtoPage.getRecords(); List<WaterResourceDto> records = waterResourceDtoPage.getRecords();
records.forEach(i->{ records.forEach(i->{
Map<String, List<AttachmentDto>> attachments = sourceFileService.getAttachments(i.getSequenceNbr()); Map<String, List<AttachmentDto>> attachments = sourceFileService.getAttachments(i.getSequenceNbr());
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment