puhanshu
2022-01-06 d70f4c1ceed4a967613850ab530ee2b8edd4f3dc
大屏修改-3133
4个文件已修改
42 ■■■■ 已修改文件
springcloud_k8s_panzhihuazhihuishequ/service_community/src/main/java/com/panzhihua/service_community/dao/ComMngPopulationDAO.java 7 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
springcloud_k8s_panzhihuazhihuishequ/service_community/src/main/java/com/panzhihua/service_community/service/impl/ComMngPopulationServiceImpl.java 9 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
springcloud_k8s_panzhihuazhihuishequ/service_community/src/main/resources/mapper/ComMngPopulationDOMapper.xml 17 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
springcloud_k8s_panzhihuazhihuishequ/service_grid/src/main/resources/mapper/EventMapper.xml 9 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
springcloud_k8s_panzhihuazhihuishequ/service_community/src/main/java/com/panzhihua/service_community/dao/ComMngPopulationDAO.java
@@ -685,4 +685,11 @@
     * @return
     */
    IPage<EventGridIncidentStatisticsVO> pageEventList(@Param("page") Page page, @Param("pageBaseDTO") PageBaseDTO pageBaseDTO);
    /**
     * 大屏事件详情新处理方式
     * @param eventId
     * @return
     */
    EventNewStatisticsVO getEventScreenSSPDateilNew(@Param("eventId") Long eventId);
}
springcloud_k8s_panzhihuazhihuishequ/service_community/src/main/java/com/panzhihua/service_community/service/impl/ComMngPopulationServiceImpl.java
@@ -7408,8 +7408,13 @@
    public R getScreenEventDetail(BigScreenEventDetailDTO eventDetailDTO) {
        EventNewStatisticsVO statisticsVO = new EventNewStatisticsVO();
        Integer eventType = eventDetailDTO.getEventType();
        if (eventDetailDTO.getType().equals(7) || (nonNull(eventType) && eventType.equals(2))) {// 随手拍详情
            statisticsVO = this.baseMapper.getEventScreenSSPDateil(eventDetailDTO.getEventId());
        boolean isNewReq = nonNull(eventType) && eventType.equals(2);
        if (eventDetailDTO.getType().equals(7) || isNewReq) {// 随手拍详情
            if (isNewReq) {
                statisticsVO = this.baseMapper.getEventScreenSSPDateilNew(eventDetailDTO.getEventId());
            } else {
                statisticsVO = this.baseMapper.getEventScreenSSPDateil(eventDetailDTO.getEventId());
            }
            if (statisticsVO != null && StringUtils.isNotEmpty(statisticsVO.getPhotoPathList())) {
                statisticsVO.setDangerLevel("0");
                statisticsVO.setMajor(false);
springcloud_k8s_panzhihuazhihuishequ/service_community/src/main/resources/mapper/ComMngPopulationDOMapper.xml
@@ -1149,4 +1149,21 @@
        </if>
        ) ORDER BY create_at DESC
    </select>
    <select id="getEventScreenSSPDateilNew"
            resultType="com.panzhihua.common.model.vos.community.screen.event.EventNewStatisticsVO">
        SELECT  id,  su.nick_name AS userName,  su.image_url,  caep.create_at,  caep.detail AS eventDes,
        caep.happen_addr AS happenAddress,  caep.lng_lat AS happentLatLng,  caep.photo_path_list,
        CASE
        WHEN classify_id = 4 THEN 1
        WHEN classify_id = 6 THEN 2
        WHEN classify_id = 5 THEN 3
        WHEN classify_id = 7 THEN 5
        WHEN classify_id = 3 THEN 6
        WHEN classify_id = 8 THEN 9
        WHEN classify_id = 1 THEN 10
        END eventType,  caep.status AS eventDealStatus
        FROM  com_act_easy_photo AS caep
        LEFT JOIN sys_user AS su ON su.user_id = caep.sponsor_id
        WHERE  id = #{eventId}
    </select>
</mapper>
springcloud_k8s_panzhihuazhihuishequ/service_grid/src/main/resources/mapper/EventMapper.xml
@@ -1438,9 +1438,10 @@
    <select id="getVillagePopulationTotalNew"
            resultType="com.panzhihua.common.model.vos.screen.ScreenDrawEventPopulationTotalVO">
        SELECT
        (SELECT count(id) FROM com_mng_population WHERE village_id = #{villageId}) as populationTotal,
        (select count(id) from com_mng_building where village_id = #{villageId}) as buildTotal,
        (SELECT COUNT(DISTINCT CONCAT(road,door_no,floor,unit_no,house_no)) FROM com_mng_population WHERE village_id = #{villageId}) as houseTotal,
        (SELECT count(id) FROM com_mng_population WHERE road = ( SELECT alley FROM com_mng_village WHERE village_id = #{villageId} )
        AND door_no = ( SELECT house_num FROM com_mng_village WHERE village_id = #{villageId} )) as populationTotal,
        (SELECT count(id) from com_mng_building where village_id = #{villageId}) as buildTotal,
        (SELECT count(id) FROM com_mng_population_house WHERE village_id = #{villageId}) as houseTotal,
        (select count(id) from com_mng_population where village_id = #{villageId} and out_or_local = 1) as localTotal,
        (select count(id) from com_mng_population where village_id = #{villageId} and out_or_local = 2) as outTotal,
        (SELECT COUNT(t1.id) FROM com_disability_population t1 LEFT JOIN com_mng_population t2 ON t1.population_id = t2.id WHERE t2.village_id = #{villageId}) as disabilityTotal,
@@ -1486,7 +1487,7 @@
            <foreach collection="villageIds" index="index" item="item" open="(" separator="," close=")">
                #{item}
            </foreach>
            ) temp GROUP BY filed
            ) temp WHERE filed is not null GROUP BY filed
            UNION ALL
            (SELECT '0-18岁' AS filed, 0 AS num)
            UNION ALL