linwe
2023-12-23 55d677758efadb6d42e6d4e595cecc2c50c20d5a
src/main/java/org/springblade/modules/task/mapper/TaskMapper.xml
@@ -67,11 +67,11 @@
        <if test="task.isDeleted != null ">and jt.is_deleted = #{task.isDeleted}</if>
        <if test="task.houseCode != null  and task.houseCode != ''">and jt.house_code = #{task.houseCode}</if>
        <!-- 取保候审 -->
        <if test="reportType != null and reportType == 1 ">
        <if test="task.reportType != null and task.reportType == 1 ">
            and jt.report_type = 1
        </if>
        <!-- 场所店铺 -->
        <if test="reportType != null and reportType == 2 ">
        <if test="task.reportType != null and task.reportType == 2 ">
            and jt.report_type in (2,3,4,5,6)
        </if>
@@ -116,4 +116,30 @@
    </select>
    <select id="selectTaskPageBy" resultType="org.springblade.modules.task.vo.TaskVO">
        SELECT
        jt.* ,
        jda.address_name
        FROM
        jczz_task jt
        LEFT JOIN jczz_doorplate_address jda ON jt.house_code = jda.address_code
        LEFT JOIN jczz_community jc ON jc.CODE = jda.nei_code
        <where>
            <if test="task.reportType != null and task.reportType != '' and task.reportType == 1">
                AND jt.report_type = #{task.reportType}
            </if>
            <if test="task.reportType == null or task.reportType == ''">
                AND jt.report_type in (2,3,6)
            </if>
            <if test="task.userId != null and task.userId != ''">
                AND jc.res_police_user_id = #{task.userId}
            </if>
        </where>
    </select>
</mapper>