Enhance surcharge management by adding support for price type filtering in SurchargeController and related services. Introduce new methods for handling redline product codes in mappers and services. Update front-end API to accommodate price type parameters in surcharge queries. Modify database schema to include redline product and country tables for improved surcharge calculations.

This commit is contained in:
wuweihua
2026-10-09 17:30:29 +08:00
parent 380577f691
commit f1f6ddd368
34 changed files with 5196 additions and 30 deletions
@@ -35,11 +35,11 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
r.created_by, r.create_time, r.updated_by, r.update_time,
s.sc_name, s.fee_type, s.charge_type, s.charge_value, s.currency,
s.round_mode, s.ss_code, s.sc_note,
c.country_name, c.weight_min, c.weight_max
ifnull(c.country_name, rc.country_name) as country_name, ifnull(c.weight_min, rc.weight_min) as weight_min, ifnull(c.weight_max, rc.weight_max) as weight_max
from prc_surcharge_rel r
join prc_surcharge s on s.sc_id = r.sc_id
left join product_country c on c.detail_id = r.detail_id
and r.price_type in ('PRODUCT', 'REDLINE')
left join product_country c on c.detail_id = r.detail_id and r.price_type = 'PRODUCT'
left join redline_product_country rc on rc.detail_id = r.detail_id and r.price_type = 'REDLINE'
</sql>
<select id="selectPrcSurchargeRelList" parameterType="PrcSurchargeRel" resultMap="PrcSurchargeRelResult">
@@ -102,7 +102,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<foreach item="code" collection="array" open="(" separator="," close=")">
#{code}
</foreach>
and price_type in ('PRODUCT', 'REDLINE')
and price_type = 'PRODUCT'
</delete>
<delete id="deleteByDetailIdsAndPriceType">