yxFwq
2024-08-13 5c2d7ece5090ed84945e42a1f89af8c279dbcb9a
src/main/resources/mapper/BasJarMastMapper.xml
@@ -53,6 +53,34 @@
        order by jar_loc_digit desc
    </select>
    <select id="getJarMastByJarIdAndStatusListB" resultMap="BaseResultMap">
        select * from asr_bas_jar_mast
        where 1=1
        and
        (
        status in
        <foreach collection="statusList" item="status" index="index" open="(" close=")" separator=",">
            #{status}
        </foreach>
        )
        and burial = #{jarId}
        order by jar_loc_digit desc
    </select>
    <select id="getJarMastByJarIdAndStatusListCharge" resultMap="BaseResultMap">
        select * from asr_bas_jar_mast
        where 1=1
        and
        (
        status not in
        <foreach collection="statusList" item="status" index="index" open="(" close=")" separator=",">
            #{status}
        </foreach>
        )
        and jar_regin = #{jarId}
        order by jar_loc_digit desc
    </select>
    <select id="getJarMastByJarIdMax" resultMap="BaseResultMap">
        select top 1 * from asr_bas_jar_mast
        where 1=1
@@ -64,6 +92,20 @@
                </foreach>
                )
          and jar_id = #{jarId}
        order by jar_loc_digit desc
    </select>
    <select id="getJarMastByJarIdMaxB" resultMap="BaseResultMap">
        select top 1 * from asr_bas_jar_mast
        where 1=1
        and
        (
        status in
        <foreach collection="statusList" item="status" index="index" open="(" close=")" separator=",">
            #{status}
        </foreach>
        )
        and burial = #{jarId}
        order by jar_loc_digit desc
    </select>
@@ -81,6 +123,20 @@
        order by jar_loc_digit asc
    </select>
    <select id="getJarMastByJarIdMinB" resultMap="BaseResultMap">
        select top 1 * from asr_bas_jar_mast
        where 1=1
        and
        (
        status in
        <foreach collection="statusList" item="status" index="index" open="(" close=")" separator=",">
            #{status}
        </foreach>
        )
        and burial = #{jarId}
        order by jar_loc_digit asc
    </select>
    <select id="getJarMastByJarIdCount" resultType="Integer">
        select count(1) from asr_bas_jar_mast
        where 1=1
@@ -88,17 +144,11 @@
    </select>
    <select id="selectJarMastOperationByStatusList" resultType="Integer">
        select count(1) from asr_bas_jar_mast
        where 1=1
          and
            (
            status in
            <foreach collection="statusList" item="status" index="index" open="(" close=")" separator=",">
                #{status}
            </foreach>
            )
          and jar_id = #{jarId}
        order by jar_loc_digit desc
        SELECT count(1) FROM [dbo].[asr_bas_jar_mast] WHERE status in
        <foreach collection="statusList" item="status" index="index" open="(" close=")" separator=",">
            #{status}
        </foreach>
        AND jar_id = #{jarId}
    </select>
    <update id="updateStatus">