linwei
2024-01-23 bff48e0801af8d8bdc8d73dce2a7b007e8af4235
src/main/java/org/springblade/modules/task/mapper/TaskReportForRepairsMapper.xml
@@ -258,14 +258,14 @@
            jczz_doorplate_address jda
            LEFT JOIN jczz_community jc ON jc.CODE = jda.nei_code
            WHERE
            jc.res_police_user_id = #{userId})
            jc.res_police_user_id like concat('%',#{userId},'%'))
            )
        </if>
    </select>
    <select id="getStatisticsCount" resultType="org.springblade.modules.task.vo.TaskReportStatistics">
        ELECT
        SELECT
        count( 1 ) AS total,
        ifnull( sum( CASE WHEN STATUS = 10 THEN 1 ELSE 0 END ), 0 ) AS handle
        FROM
@@ -273,14 +273,23 @@
        LEFT JOIN jczz_doorplate_address jda ON jda.address_code = jtrfr.address_code
        WHERE is_deleted = 0
        <if test="userId != null">
            and create_user = #{userId}
            and jtrfr.create_user = #{userId}
        </if>
        <if test="houseCode != null and houseCode != ''">
            and address_code = #{houseCode}
            and jtrfr.address_code = #{houseCode}
        </if>
        <if test="neiCode != null and neiCode != ''">
            AND jda.nei_code LIKE concat( #{neiCode}, '%' )
        <if test="isAdministrator==2">
            <choose>
                <when test="regionChildCodesList !=null and regionChildCodesList.size()>0">
                    and jda.nei_code in
                    <foreach collection="regionChildCodesList" item="code" open="(" close=")" separator=",">
                        #{code}
                    </foreach>
                </when>
                <otherwise>
                    and jda.nei_code in ('')
                </otherwise>
            </choose>
        </if>
    </select>