增加软删除
This commit is contained in:
@@ -13,6 +13,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||
<result property="currency" column="currency" />
|
||||
<result property="roundMode" column="round_mode" />
|
||||
<result property="ssCode" column="ss_code" />
|
||||
<result property="isDel" column="is_del" />
|
||||
<result property="countryCode" column="country_code" />
|
||||
<result property="scNote" column="sc_note" />
|
||||
<result property="tmsId" column="tms_id" />
|
||||
@@ -23,7 +24,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||
</resultMap>
|
||||
|
||||
<sql id="selectPrcSurchargeVo">
|
||||
select sc_id, sc_name, fee_type, charge_type, charge_value, currency, round_mode, ss_code,
|
||||
select sc_id, sc_name, fee_type, charge_type, charge_value, currency, round_mode, ss_code, is_del,
|
||||
country_code, sc_note, tms_id, created_by, create_time, updated_by, update_time
|
||||
from prc_surcharge
|
||||
</sql>
|
||||
@@ -31,11 +32,13 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||
<select id="selectPrcSurchargeById" parameterType="Long" resultMap="PrcSurchargeResult">
|
||||
<include refid="selectPrcSurchargeVo"/>
|
||||
where sc_id = #{scId}
|
||||
and ifnull(is_del, '0') = '0'
|
||||
</select>
|
||||
|
||||
<select id="selectPrcSurchargeList" parameterType="PrcSurcharge" resultMap="PrcSurchargeResult">
|
||||
<include refid="selectPrcSurchargeVo"/>
|
||||
<where>
|
||||
and ifnull(is_del, '0') = '0'
|
||||
<if test="scName != null and scName != ''">
|
||||
AND sc_name like concat('%', #{scName}, '%')
|
||||
</if>
|
||||
@@ -76,6 +79,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||
<if test="currency != null and currency != ''">currency,</if>
|
||||
<if test="roundMode != null and roundMode != ''">round_mode,</if>
|
||||
<if test="ssCode != null and ssCode != ''">ss_code,</if>
|
||||
is_del,
|
||||
<if test="countryCode != null">country_code,</if>
|
||||
<if test="scNote != null">sc_note,</if>
|
||||
<if test="tmsId != null">tms_id,</if>
|
||||
@@ -89,6 +93,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||
<if test="currency != null and currency != ''">#{currency},</if>
|
||||
<if test="roundMode != null and roundMode != ''">#{roundMode},</if>
|
||||
<if test="ssCode != null and ssCode != ''">#{ssCode},</if>
|
||||
ifnull(#{isDel}, '0'),
|
||||
<if test="countryCode != null">#{countryCode},</if>
|
||||
<if test="scNote != null">#{scNote},</if>
|
||||
<if test="tmsId != null">#{tmsId},</if>
|
||||
@@ -101,7 +106,8 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||
<update id="updateSsCodeByIds">
|
||||
update prc_surcharge
|
||||
set ss_code = #{ssCode}, updated_by = #{operator}, update_time = sysdate()
|
||||
where sc_id in
|
||||
where ifnull(is_del, '0') = '0'
|
||||
and sc_id in
|
||||
<foreach item="scId" collection="scIds" open="(" separator="," close=")">
|
||||
#{scId}
|
||||
</foreach>
|
||||
|
||||
Reference in New Issue
Block a user