101captain
2021-12-27 e0ae336140bc832a93f458666354fc77b336e158
12/27  大屏代码修改
3个文件已修改
44 ■■■■■ 已修改文件
springcloud_k8s_panzhihuazhihuishequ/service_community/src/main/java/com/panzhihua/service_community/service/impl/ComMngPopulationServiceImpl.java 36 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
springcloud_k8s_panzhihuazhihuishequ/service_community/src/main/resources/mapper/ComActReserveMapper.xml 6 ●●●● 补丁 | 查看 | 原始文档 | blame | 历史
springcloud_k8s_panzhihuazhihuishequ/service_community/src/main/resources/mapper/ComMngPopulationDOMapper.xml 2 ●●● 补丁 | 查看 | 原始文档 | blame | 历史
springcloud_k8s_panzhihuazhihuishequ/service_community/src/main/java/com/panzhihua/service_community/service/impl/ComMngPopulationServiceImpl.java
@@ -7823,35 +7823,43 @@
        IndexSpecialStatisticsVO otherSpecialVO = new IndexSpecialStatisticsVO();
        otherSpecialVO.setTitle("其他");
        otherSpecialVO.setSum(0);
        int countAll=comMngPopulationDAO.getSpecialStatistics(communityId);
        IndexSpecialStatisticsVO otherSpecialVO1 = new IndexSpecialStatisticsVO();
        otherSpecialVO1.setTitle("普通居民");
        otherSpecialVO1.setSum(0);
        int countNormal=comMngPopulationDAO.getSpecialStatistics(communityId);
        int countElder=comMngPopulationDAO.getStatisticsCount(communityId);
        int countAll=countElder+countNormal;
        if (!userTagList.isEmpty()) {
            userTagList.forEach(userTag -> {
                if (userTag != null) {
                    if (userTag.getSysFlag().equals(0)) {
                        Integer count = comMngPopulationDAO.getSpecialStatisticsByLabel(userTag.getTagName(),communityId);
                        IndexSpecialStatisticsVO specialStatisticsVO = new IndexSpecialStatisticsVO();
                        otherSpecialVO.setSum(otherSpecialVO.getSum()+count);
                        specialStatisticsVO.setTitle(userTag.getTagName());
                        specialStatisticsVO.setSum(count);
                        specialStatisticsVO.setPercent(BigDecimal.valueOf(specialStatisticsVO.getSum()*100d/countAll).setScale(2,BigDecimal.ROUND_HALF_UP));
                        specialStatisticsVOList.add(specialStatisticsVO);
                    } else {
                        if (StringUtils.isNotEmpty(userTag.getTagName())) {
                    if(userTag.getTagName().equals("高龄老人")||userTag.getTagName().equals("残疾人")||userTag.getTagName().equals("低保户")||userTag.getTagName().equals("退役军人")||userTag.getTagName().equals("养老金人员")||userTag.getTagName().equals("低保户")){
                                IndexSpecialStatisticsVO specialStatisticsVO = new IndexSpecialStatisticsVO();
                                specialStatisticsVO.setTitle(userTag.getTagName());
                                Integer count = comMngPopulationDAO.getSpecialStatisticsByLabel(userTag.getTagName(),communityId);
                                otherSpecialVO.setSum(otherSpecialVO.getSum()+count);
                        Integer count =0;
                        if (userTag.getTagName().equals("高龄老人")) {
                            count=countElder;
                        }
                        else {
                            count= comMngPopulationDAO.getSpecialStatisticsByLabel(userTag.getTagName(),communityId);
                        }
                                specialStatisticsVO.setSum(count);
                                specialStatisticsVO.setPercent(BigDecimal.valueOf(specialStatisticsVO.getSum()*100d/countAll).setScale(2,BigDecimal.ROUND_HALF_UP));
                        otherSpecialVO1.setSum(otherSpecialVO1.getSum()+count);
                                specialStatisticsVOList.add(specialStatisticsVO);
                        }
                    else{
                        Integer count = comMngPopulationDAO.getSpecialStatisticsByLabel(userTag.getTagName(),communityId);
                        otherSpecialVO.setSum(otherSpecialVO.getSum()+count);
                        otherSpecialVO1.setSum(otherSpecialVO1.getSum()+count);
                    }
                }
            });
        }
        otherSpecialVO.setSum(countAll-otherSpecialVO.getSum());
        otherSpecialVO.setPercent(BigDecimal.valueOf(otherSpecialVO.getSum()*100d/countAll).setScale(2,BigDecimal.ROUND_HALF_UP));
        specialStatisticsVOList.add(otherSpecialVO);
        otherSpecialVO1.setSum(countAll-otherSpecialVO1.getSum());
        otherSpecialVO1.setPercent(BigDecimal.valueOf(otherSpecialVO1.getSum()*100d/countAll).setScale(2,BigDecimal.ROUND_HALF_UP));
        specialStatisticsVOList.add(otherSpecialVO1);
        indexInfo.setSpecialStatisticsVOList(specialStatisticsVOList);
        // 查询网格化治理
        IndexEventGridStatisticsVO eventGridStatisticsVO = new IndexEventGridStatisticsVO();
springcloud_k8s_panzhihuazhihuishequ/service_community/src/main/resources/mapper/ComActReserveMapper.xml
@@ -194,7 +194,7 @@
    </select>
    <select id="indexBackReserve" resultType="Integer">
        select count(*) from com_act_reserve t  LEFT JOIN com_act_reserve_record t3 on t.id=t3.reserve_id where t.community_id = #{communityId} and t.title like '%返攀登记%'
        select count(*) from com_act_reserve t  LEFT JOIN com_act_reserve_record t3 on t.id=t3.reserve_id where t.community_id = #{communityId} and ( t.title like '%返攀登记%' or t.title like '%来攀登记%')
    </select>
    <select id="indexHomeQuarantine" resultType="Integer">
@@ -205,11 +205,11 @@
        select a.*,IFNULL(b.num,0) num from (select count(t2.id) as allCount,t1.key from com_act_reserve t
                                                                                             LEFT JOIN com_act_reserve_sub t1 on t.id = t1.reserve_id
                                                                                             LEFT JOIN com_act_reserve_answer_content t2 on t1.id = t2.reserve_sub_id
                                             where t.community_id = #{communityId} and t.title like '%返攀登记%' and t1.`key` in (1,2,3,17,19,26) group by t1.key) a LEFT JOIN
                                             where t.community_id = #{communityId} and ( t.title like '%返攀登记%' or t.title like '%来攀登记%') and t1.`key` in (1,2,3,17,19,26) group by t1.key) a LEFT JOIN
                                            (select count(t2.id) as num,t1.key from com_act_reserve t
                                                                                        LEFT JOIN com_act_reserve_sub t1 on t.id = t1.reserve_id
                                                                                        LEFT JOIN com_act_reserve_answer_content t2 on t1.id = t2.reserve_sub_id
                                             where t.community_id = #{communityId} and t.title like '%返攀登记%' and t1.`key` in (1,2,3,17,19,26) and t2.answer_content = '是' group by t1.key) b on a.key = b.key
                                             where t.community_id = #{communityId} and ( t.title like '%返攀登记%' or t.title like '%来攀登记%') and t1.`key` in (1,2,3,17,19,26) and t2.answer_content = '是' group by t1.key) b on a.key = b.key
    </select>
    <select id="IndexHomeQuarantineSub" resultType="com.panzhihua.common.model.vos.community.bigscreen.IndexReserveSub">
springcloud_k8s_panzhihuazhihuishequ/service_community/src/main/resources/mapper/ComMngPopulationDOMapper.xml
@@ -1067,7 +1067,7 @@
    <select id="indexDynamic" resultType="com.panzhihua.common.model.vos.community.bigscreen.IndexDynamic">
        SELECT    count( id ) AS microWish,
                  IFNULL(( SELECT count( id ) FROM com_act_easy_photo WHERE status = 4 AND community_id = camw.community_id ),0) AS easyPhoto,
                  IFNULL(( SELECT count( id ) FROM com_act_easy_photo WHERE status in (1,2,4) and del_tag = 0 AND community_id = camw.community_id ),0) AS easyPhoto,
                  IFNULL(( SELECT count( id ) FROM com_pb_activity WHERE STATUS = 5 AND community_id = camw.community_id ),0) AS partyActivity,
                  IFNULL(( SELECT count( id ) FROM com_act_questnaire WHERE community_id = camw.community_id and is_hide=0 ),0) AS questionnaire,
                  IFNULL(( SELECT count( id ) FROM com_act_dyn WHERE community_id = camw.community_id AND STATUS = 1 ),0) AS dynamic,