111
This commit is contained in:
1 parent
81eca8933a
commit
345f906c35
540 files changed
+494222
-90
No files matched your search
@@ -0,0 +1,191 @@
|
||||
<?xml version="1.0" encoding="UTF-8" ?>
|
||||
<!DOCTYPE mapper
|
||||
PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
||||
"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||
<mapper namespace="com.ruoyi.custom.mapper.CustomOrderItemMapper">
|
||||
|
||||
<resultMap type="CustomOrderItem" id="CustomOrderItemResult">
|
||||
<result property="id" column="id" />
|
||||
<result property="orderId" column="order_id" />
|
||||
<result property="declarePortId" column="declare_port_id" />
|
||||
<result property="warehouseId" column="warehouse_id" />
|
||||
<result property="barCode" column="bar_code" />
|
||||
<result property="quantity" column="quantity" />
|
||||
<result property="price" column="price" />
|
||||
<result property="shopPrice" column="shop_price" />
|
||||
<result property="freight" column="freight" />
|
||||
<result property="taxAmount" column="tax_amount" />
|
||||
<result property="itemLink" column="item_link" />
|
||||
<result property="bookNumber" column="book_number" />
|
||||
<result property="productCode" column="product_code" />
|
||||
<result property="name" column="name" />
|
||||
<result property="brand" column="brand" />
|
||||
<result property="specificationModel" column="specification_model" />
|
||||
<result property="description" column="description" />
|
||||
<result property="quantityUnit" column="quantity_unit" />
|
||||
<result property="produceCountry" column="produce_country" />
|
||||
<result property="inspectionAndQuarantineCode" column="inspection_and_quarantine_code" />
|
||||
<result property="hsCode" column="hs_code" />
|
||||
<result property="taxRate" column="tax_rate" />
|
||||
<result property="declaredCount" column="declared_count" />
|
||||
<result property="legalMeteringUnit" column="legal_metering_unit" />
|
||||
<result property="secondDeclaredCount" column="second_declared_count" />
|
||||
<result property="secondMeteringUnit" column="second_metering_unit" />
|
||||
<result property="grossWeight" column="gross_weight" />
|
||||
<result property="netWeight" column="net_weight" />
|
||||
<result property="skuCode" column="sku_code" />
|
||||
</resultMap>
|
||||
|
||||
<sql id="selectCustomOrderItemVo">
|
||||
select id, order_id, declare_port_id, warehouse_id, bar_code, quantity, price, shop_price, freight, tax_amount, item_link, book_number, product_code, name, brand, specification_model, description, quantity_unit, produce_country, inspection_and_quarantine_code, hs_code, tax_rate, declared_count, legal_metering_unit, second_declared_count, second_metering_unit, gross_weight, net_weight from custom_order_item
|
||||
</sql>
|
||||
|
||||
<select id="selectCustomOrderItemList" parameterType="CustomOrderItem" resultMap="CustomOrderItemResult">
|
||||
<include refid="selectCustomOrderItemVo"/>
|
||||
<where>
|
||||
<if test="orderId != null "> and order_id = #{orderId}</if>
|
||||
<if test="declarePortId != null "> and declare_port_id = #{declarePortId}</if>
|
||||
<if test="warehouseId != null "> and warehouse_id = #{warehouseId}</if>
|
||||
<if test="barCode != null and barCode != ''"> and bar_code = #{barCode}</if>
|
||||
<if test="quantity != null "> and quantity = #{quantity}</if>
|
||||
<if test="price != null "> and price = #{price}</if>
|
||||
<if test="shopPrice != null "> and shop_price = #{shopPrice}</if>
|
||||
<if test="freight != null "> and freight = #{freight}</if>
|
||||
<if test="taxAmount != null "> and tax_amount = #{taxAmount}</if>
|
||||
<if test="itemLink != null and itemLink != ''"> and item_link = #{itemLink}</if>
|
||||
<if test="bookNumber != null and bookNumber != ''"> and book_number = #{bookNumber}</if>
|
||||
<if test="productCode != null and productCode != ''"> and product_code = #{productCode}</if>
|
||||
<if test="name != null and name != ''"> and name like concat('%', #{name}, '%')</if>
|
||||
<if test="brand != null and brand != ''"> and brand = #{brand}</if>
|
||||
<if test="specificationModel != null and specificationModel != ''"> and specification_model = #{specificationModel}</if>
|
||||
<if test="description != null and description != ''"> and description = #{description}</if>
|
||||
<if test="quantityUnit != null and quantityUnit != ''"> and quantity_unit = #{quantityUnit}</if>
|
||||
<if test="produceCountry != null and produceCountry != ''"> and produce_country = #{produceCountry}</if>
|
||||
<if test="inspectionAndQuarantineCode != null and inspectionAndQuarantineCode != ''"> and inspection_and_quarantine_code = #{inspectionAndQuarantineCode}</if>
|
||||
<if test="hsCode != null and hsCode != ''"> and hs_code = #{hsCode}</if>
|
||||
<if test="taxRate != null "> and tax_rate = #{taxRate}</if>
|
||||
<if test="declaredCount != null "> and declared_count = #{declaredCount}</if>
|
||||
<if test="legalMeteringUnit != null and legalMeteringUnit != ''"> and legal_metering_unit = #{legalMeteringUnit}</if>
|
||||
<if test="secondDeclaredCount != null "> and second_declared_count = #{secondDeclaredCount}</if>
|
||||
<if test="secondMeteringUnit != null and secondMeteringUnit != ''"> and second_metering_unit = #{secondMeteringUnit}</if>
|
||||
<if test="grossWeight != null "> and gross_weight = #{grossWeight}</if>
|
||||
<if test="netWeight != null "> and net_weight = #{netWeight}</if>
|
||||
<if test="skuCode != null "> and sku_code = #{skuCode}</if>
|
||||
</where>
|
||||
</select>
|
||||
|
||||
<select id="selectCustomOrderItemById" parameterType="Long" resultMap="CustomOrderItemResult">
|
||||
<include refid="selectCustomOrderItemVo"/>
|
||||
where id = #{id}
|
||||
</select>
|
||||
|
||||
<insert id="insertCustomOrderItem" parameterType="CustomOrderItem" useGeneratedKeys="true" keyProperty="id">
|
||||
insert into custom_order_item
|
||||
<trim prefix="(" suffix=")" suffixOverrides=",">
|
||||
<if test="orderId != null">order_id,</if>
|
||||
<if test="declarePortId != null">declare_port_id,</if>
|
||||
<if test="warehouseId != null">warehouse_id,</if>
|
||||
<if test="barCode != null">bar_code,</if>
|
||||
<if test="quantity != null">quantity,</if>
|
||||
<if test="price != null">price,</if>
|
||||
<if test="shopPrice != null">shop_price,</if>
|
||||
<if test="freight != null">freight,</if>
|
||||
<if test="taxAmount != null">tax_amount,</if>
|
||||
<if test="itemLink != null">item_link,</if>
|
||||
<if test="bookNumber != null">book_number,</if>
|
||||
<if test="productCode != null">product_code,</if>
|
||||
<if test="name != null">name,</if>
|
||||
<if test="brand != null">brand,</if>
|
||||
<if test="specificationModel != null">specification_model,</if>
|
||||
<if test="description != null">description,</if>
|
||||
<if test="quantityUnit != null">quantity_unit,</if>
|
||||
<if test="produceCountry != null">produce_country,</if>
|
||||
<if test="inspectionAndQuarantineCode != null">inspection_and_quarantine_code,</if>
|
||||
<if test="hsCode != null">hs_code,</if>
|
||||
<if test="taxRate != null">tax_rate,</if>
|
||||
<if test="declaredCount != null">declared_count,</if>
|
||||
<if test="legalMeteringUnit != null">legal_metering_unit,</if>
|
||||
<if test="secondDeclaredCount != null">second_declared_count,</if>
|
||||
<if test="secondMeteringUnit != null">second_metering_unit,</if>
|
||||
<if test="grossWeight != null">gross_weight,</if>
|
||||
<if test="netWeight != null">net_weight,</if>
|
||||
<if test="skuCode != null">sku_code,</if>
|
||||
</trim>
|
||||
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
||||
<if test="orderId != null">#{orderId},</if>
|
||||
<if test="declarePortId != null">#{declarePortId},</if>
|
||||
<if test="warehouseId != null">#{warehouseId},</if>
|
||||
<if test="barCode != null">#{barCode},</if>
|
||||
<if test="quantity != null">#{quantity},</if>
|
||||
<if test="price != null">#{price},</if>
|
||||
<if test="shopPrice != null">#{shopPrice},</if>
|
||||
<if test="freight != null">#{freight},</if>
|
||||
<if test="taxAmount != null">#{taxAmount},</if>
|
||||
<if test="itemLink != null">#{itemLink},</if>
|
||||
<if test="bookNumber != null">#{bookNumber},</if>
|
||||
<if test="productCode != null">#{productCode},</if>
|
||||
<if test="name != null">#{name},</if>
|
||||
<if test="brand != null">#{brand},</if>
|
||||
<if test="specificationModel != null">#{specificationModel},</if>
|
||||
<if test="description != null">#{description},</if>
|
||||
<if test="quantityUnit != null">#{quantityUnit},</if>
|
||||
<if test="produceCountry != null">#{produceCountry},</if>
|
||||
<if test="inspectionAndQuarantineCode != null">#{inspectionAndQuarantineCode},</if>
|
||||
<if test="hsCode != null">#{hsCode},</if>
|
||||
<if test="taxRate != null">#{taxRate},</if>
|
||||
<if test="declaredCount != null">#{declaredCount},</if>
|
||||
<if test="legalMeteringUnit != null">#{legalMeteringUnit},</if>
|
||||
<if test="secondDeclaredCount != null">#{secondDeclaredCount},</if>
|
||||
<if test="secondMeteringUnit != null">#{secondMeteringUnit},</if>
|
||||
<if test="grossWeight != null">#{grossWeight},</if>
|
||||
<if test="netWeight != null">#{netWeight},</if>
|
||||
<if test="skuCode != null">#{skuCode},</if>
|
||||
</trim>
|
||||
</insert>
|
||||
|
||||
<update id="updateCustomOrderItem" parameterType="CustomOrderItem">
|
||||
update custom_order_item
|
||||
<trim prefix="SET" suffixOverrides=",">
|
||||
<if test="orderId != null">order_id = #{orderId},</if>
|
||||
<if test="declarePortId != null">declare_port_id = #{declarePortId},</if>
|
||||
<if test="warehouseId != null">warehouse_id = #{warehouseId},</if>
|
||||
<if test="barCode != null">bar_code = #{barCode},</if>
|
||||
<if test="quantity != null">quantity = #{quantity},</if>
|
||||
<if test="price != null">price = #{price},</if>
|
||||
<if test="shopPrice != null">shop_price = #{shopPrice},</if>
|
||||
<if test="freight != null">freight = #{freight},</if>
|
||||
<if test="taxAmount != null">tax_amount = #{taxAmount},</if>
|
||||
<if test="itemLink != null">item_link = #{itemLink},</if>
|
||||
<if test="bookNumber != null">book_number = #{bookNumber},</if>
|
||||
<if test="productCode != null">product_code = #{productCode},</if>
|
||||
<if test="name != null">name = #{name},</if>
|
||||
<if test="brand != null">brand = #{brand},</if>
|
||||
<if test="specificationModel != null">specification_model = #{specificationModel},</if>
|
||||
<if test="description != null">description = #{description},</if>
|
||||
<if test="quantityUnit != null">quantity_unit = #{quantityUnit},</if>
|
||||
<if test="produceCountry != null">produce_country = #{produceCountry},</if>
|
||||
<if test="inspectionAndQuarantineCode != null">inspection_and_quarantine_code = #{inspectionAndQuarantineCode},</if>
|
||||
<if test="hsCode != null">hs_code = #{hsCode},</if>
|
||||
<if test="taxRate != null">tax_rate = #{taxRate},</if>
|
||||
<if test="declaredCount != null">declared_count = #{declaredCount},</if>
|
||||
<if test="legalMeteringUnit != null">legal_metering_unit = #{legalMeteringUnit},</if>
|
||||
<if test="secondDeclaredCount != null">second_declared_count = #{secondDeclaredCount},</if>
|
||||
<if test="secondMeteringUnit != null">second_metering_unit = #{secondMeteringUnit},</if>
|
||||
<if test="grossWeight != null">gross_weight = #{grossWeight},</if>
|
||||
<if test="netWeight != null">net_weight = #{netWeight},</if>
|
||||
<if test="skuCode != null">sku_code = #{skuCode},</if>
|
||||
</trim>
|
||||
where id = #{id}
|
||||
</update>
|
||||
|
||||
<delete id="deleteCustomOrderItemById" parameterType="Long">
|
||||
delete from custom_order_item where id = #{id}
|
||||
</delete>
|
||||
|
||||
<delete id="deleteCustomOrderItemByIds" parameterType="String">
|
||||
delete from custom_order_item where id in
|
||||
<foreach item="id" collection="array" open="(" separator="," close=")">
|
||||
#{id}
|
||||
</foreach>
|
||||
</delete>
|
||||
</mapper>
|
||||
Reference in new issue
Block a user