LuoTong
2024-04-23 898892c5114dcd2be4bedcd711fc016e1af4c431
双报到双服务 问题清单 bug修改
1个文件已修改
20 ■■■■■ 已修改文件
springcloud_k8s_panzhihuazhihuishequ/service_community/src/main/resources/mapper/ComActDaoMapper.xml 20 ●●●●● 补丁 | 查看 | 原始文档 | blame | 历史
springcloud_k8s_panzhihuazhihuishequ/service_community/src/main/resources/mapper/ComActDaoMapper.xml
@@ -317,14 +317,20 @@
    <select id="qryReport" resultType="com.panzhihua.common.model.dtos.partybuilding.QryReportResp">
        SELECT
            ctn.id  as categoryId,
            sum( IF(npi.id is null,0,1) ) as sum,
            ctn.`name` as categoryName
        ctn.id as categoryId,
        sum( IF(npi.id is null,0,1) ) as sum,
        ctn.`name` as categoryName
        FROM
            com_act_neighbor_circle_topic_new AS ctn
         LEFT JOIN new_fight_need_problem_inventory AS npi ON npi.classify_id = ctn.id
        WHERE npi.creation_time &gt;= concat(#{yearTime},'-01-01 00:00:00')
            AND npi.creation_time &lt;= concat(#{yearTime},'-12-31 59:59:59')
        com_act_neighbor_circle_topic_new AS ctn
        LEFT JOIN (
        SELECT * from new_fight_need_problem_inventory
        <if test="yearTime != null and yearTime != '' ">
            WHERE
            creation_time &gt;= concat(#{yearTime},'-01-01 00:00:00')
            AND creation_time &lt;= concat(#{yearTime},'-12-31 59:59:59')
        </if>
        )
        AS npi ON npi.classify_id = ctn.id
        GROUP BY
            ctn.id