123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866 |
- <?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.kmall.admin.dao.GoodsProductDao">
- <resultMap type="com.kmall.admin.entity.GoodsProductEntity" id="goodsProductMap">
- <result property="mallGoodsProductSn" column="mall_goods_product_sn"/>
- <result property="merchSn" column="merch_sn"/>
- <result property="thirdMerchSn" column="third_merch_sn"/>
- <result property="prodBarcode" column="prod_barcode"/>
- <result property="sku" column="sku"/>
- <result property="cusGoodsCode" column="cus_goods_code"/>
- <result property="prodName" column="prod_name"/>
- <result property="prodEname" column="prod_ename"/>
- <result property="prodRecordName" column="prod_record_name"/>
- <result property="prodRecordEname" column="prod_record_ename"/>
- <result property="ciqProdModel" column="ciq_prod_model"/>
- <result property="prodBrand" column="prod_brand"/>
- <result property="oriCntCode" column="ori_cnt_code"/>
- <result property="unitCode" column="unit_code"/>
- <result property="declPrice" column="decl_price"/>
- <result property="declCurrencyCode" column="decl_currency_code"/>
- <result property="supplierName" column="supplier_name"/>
- <result property="supplierCntCode" column="supplier_cnt_code"/>
- <result property="prodCompName" column="prod_comp_name"/>
- <result property="prodCompCntCode" column="prod_comp_cnt_code"/>
- <result property="ciqMainEle" column="ciq_main_ele"/>
- <result property="ciqMonitorType" column="ciq_monitor_type"/>
- <result property="isLaw" column="is_law"/>
- <result property="isGift" column="is_gift"/>
- <result property="cusDeclEle" column="cus_decl_ele"/>
- <result property="createrSn" column="creater_sn"/>
- <result property="createTime" column="create_time"/>
- <result property="moderSn" column="moder_sn"/>
- <result property="modTime" column="mod_time"/>
- <result property="tstm" column="tstm"/>
- <result property="exField" column="ex_field"/>
- <result property="exField2" column="ex_field2"/>
- <result property="exField3" column="ex_field3"/>
- <result property="exField4" column="ex_field4"/>
- <result property="exField5" column="ex_field5"/>
- <result property="legalUnit1Qty" column="legal_unit1_qty"/>
- <result property="netWeight" column="net_weight"/>
- <result property="legalUnit2Qty" column="legal_unit2_qty"/>
- <result property="grossWeight" column="gross_weight"/>
- <result property="localEmsNo" column="local_ems_no"/>
- <result property="itemRecordNo" column="item_record_no"/>
- <result property="emsClassCode" column="ems_class_code"/>
- <result property="isSend" column="is_send"/>
- <result property="upImg" column="up_img"/>
- <result property="downImg" column="down_img"/>
- <result property="leftImg" column="left_img"/>
- <result property="rightImg" column="right_img"/>
- <result property="beforeImg" column="before_img"/>
- <result property="afterImg" column="after_img"/>
- <result property="sendTime" column="send_time"/>
- <result property="omsAuditStatus" column="oms_audit_status"/>
- <result property="omsAuditRemark" column="oms_audit_remark"/>
- <result property="omsCallbackTime" column="oms_callback_time"/>
- <result property="batchNo" column="batch_no"/>
- <result property="omsAuditTime" column="oms_audit_time"/>
- <result property="status" column="status"/>
- </resultMap>
- <select id="queryObject" resultType="com.kmall.admin.entity.GoodsProductEntity">
- select
- `mall_goods_product_sn`,
- `merch_sn`,
- `third_merch_sn`,
- `prod_barcode`,
- `sku`,
- `cus_goods_code`,
- `prod_name`,
- `prod_ename`,
- `prod_record_name`,
- `prod_record_ename`,
- `ciq_prod_model`,
- `prod_brand`,
- `ori_cnt_code`,
- `unit_code`,
- `decl_price`,
- `decl_currency_code`,
- `supplier_name`,
- `supplier_cnt_code`,
- `prod_comp_name`,
- `prod_comp_cnt_code`,
- `ciq_main_ele`,
- `ciq_monitor_type`,
- `is_law`,
- `is_gift`,
- `cus_decl_ele`,
- `creater_sn`,
- `create_time`,
- `moder_sn`,
- `mod_time`,
- `tstm`,
- `ex_field`,
- `ex_field2`,
- `ex_field3`,
- `ex_field4`,
- `ex_field5`,
- `legal_unit1_qty`,
- `net_weight`,
- `legal_unit2_qty`,
- `gross_weight`,
- `local_ems_no`,
- `item_record_no`,
- `is_send`,
- `ems_class_code`,
- `up_img`,
- `down_img`,
- `left_img`,
- `right_img`,
- `before_img`,
- `after_img`,
- `send_time`,
- `oms_audit_status`,
- `oms_audit_remark`,
- `oms_callback_time`,
- `batch_no`,
- `oms_audit_time`,
- `status`
- from mall_goods_product
- where mall_goods_product_sn = #{id}
- </select>
- <select id="queryList" resultType="com.kmall.admin.entity.GoodsProductEntity">
- select
- `mall_goods_product_sn`,
- `merch_sn`,
- `third_merch_sn`,
- `prod_barcode`,
- `sku`,
- `cus_goods_code`,
- `prod_name`,
- `prod_ename`,
- `prod_record_name`,
- `prod_record_ename`,
- `ciq_prod_model`,
- `prod_brand`,
- `ori_cnt_code`,
- `unit_code`,
- `decl_price`,
- `decl_currency_code`,
- `supplier_name`,
- `supplier_cnt_code`,
- `prod_comp_name`,
- `prod_comp_cnt_code`,
- `ciq_main_ele`,
- `ciq_monitor_type`,
- `is_law`,
- `is_gift`,
- `cus_decl_ele`,
- `creater_sn`,
- `create_time`,
- `moder_sn`,
- `mod_time`,
- `tstm`,
- `ex_field`,
- `ex_field2`,
- `ex_field3`,
- `ex_field4`,
- `ex_field5`,
- `legal_unit1_qty`,
- `net_weight`,
- `legal_unit2_qty`,
- `gross_weight`,
- `local_ems_no`,
- `item_record_no`,
- `is_send`,
- `ems_class_code`,
- `up_img`,
- `down_img`,
- `left_img`,
- `right_img`,
- `before_img`,
- `after_img`,
- `send_time`,
- `oms_audit_status`,
- `oms_audit_remark`,
- `oms_callback_time`,
- `batch_no`,
- `oms_audit_time`,
- `status`
- from mall_goods_product
- WHERE 1=1
- <if test="name != null and name.trim() != ''">
- AND `prod_name` LIKE concat('%',#{name},'%')
- </if>
- <if test="isSend != null and isSend.trim() != ''">
- AND `is_send` in (${isSend})
- </if>
- <if test="status != null and status.trim() != ''">
- AND `status` in (${status})
- </if>
- <choose>
- <when test="sidx != null and sidx.trim() != ''">
- order by ${sidx} ${order}
- </when>
- <otherwise>
- order by mall_goods_product_sn desc
- </otherwise>
- </choose>
- <if test="offset != null and limit != null">
- limit #{offset}, #{limit}
- </if>
- </select>
- <select id="queryTotal" resultType="int">
- select count(*) from mall_goods_product
- WHERE 1=1
- <if test="name != null and name.trim() != ''">
- AND `prod_name` LIKE concat('%',#{name},'%')
- </if>
- </select>
- <select id="selectByParams" resultType="com.kmall.admin.entity.GoodsProductEntity">
- select
- `mall_goods_product_sn`,
- `merch_sn`,
- `third_merch_sn`,
- `prod_barcode`,
- `sku`,
- `cus_goods_code`,
- `prod_name`,
- `prod_ename`,
- `prod_record_name`,
- `prod_record_ename`,
- `ciq_prod_model`,
- `prod_brand`,
- `ori_cnt_code`,
- `unit_code`,
- `decl_price`,
- `decl_currency_code`,
- `supplier_name`,
- `supplier_cnt_code`,
- `prod_comp_name`,
- `prod_comp_cnt_code`,
- `ciq_main_ele`,
- `ciq_monitor_type`,
- `is_law`,
- `is_gift`,
- `cus_decl_ele`,
- `creater_sn`,
- `create_time`,
- `moder_sn`,
- `mod_time`,
- `tstm`,
- `ex_field`,
- `ex_field2`,
- `ex_field3`,
- `ex_field4`,
- `ex_field5`,
- `legal_unit1_qty`,
- `net_weight`,
- `legal_unit2_qty`,
- `gross_weight`,
- `local_ems_no`,
- `item_record_no`,
- `is_send`,
- `ems_class_code`,
- `up_img`,
- `down_img`,
- `left_img`,
- `right_img`,
- `before_img`,
- `after_img`,
- `send_time`,
- `oms_audit_status`,
- `oms_audit_remark`,
- `oms_callback_time`,
- `batch_no`,
- `oms_audit_time`,
- `status`
- from mall_goods_product
- WHERE 1=1
- <if test="sku != null and sku.trim() != ''">
- AND sku = #{sku}
- </if>
- <if test="merchSn != null and merchSn.trim() != ''">
- AND merch_sn = #{merchSn}
- </if>
- <if test="thirdMerchSn != null and thirdMerchSn.trim() != ''">
- AND third_merch_sn = #{thirdMerchSn}
- </if>
- <if test="prodBarcode != null and prodBarcode.trim() != ''">
- AND prod_barcode = #{prodBarcode}
- </if>
- </select>
- <select id="selectByMallGoodsProductSns" resultType="com.kmall.admin.entity.GoodsProductEntity">
- select
- `mall_goods_product_sn`,
- `merch_sn`,
- `third_merch_sn`,
- `prod_barcode`,
- `sku`,
- `cus_goods_code`,
- `prod_name`,
- `prod_ename`,
- `prod_record_name`,
- `prod_record_ename`,
- `ciq_prod_model`,
- `prod_brand`,
- `ori_cnt_code`,
- `unit_code`,
- `decl_price`,
- `decl_currency_code`,
- `supplier_name`,
- `supplier_cnt_code`,
- `prod_comp_name`,
- `prod_comp_cnt_code`,
- `ciq_main_ele`,
- `ciq_monitor_type`,
- `is_law`,
- `is_gift`,
- `cus_decl_ele`,
- `creater_sn`,
- `create_time`,
- `moder_sn`,
- `mod_time`,
- `tstm`,
- `ex_field`,
- `ex_field2`,
- `ex_field3`,
- `ex_field4`,
- `ex_field5`,
- `legal_unit1_qty`,
- `net_weight`,
- `legal_unit2_qty`,
- `gross_weight`,
- `local_ems_no`,
- `item_record_no`,
- `is_send`,
- `ems_class_code`,
- `up_img`,
- `down_img`,
- `left_img`,
- `right_img`,
- `before_img`,
- `after_img`,
- `send_time`,
- `oms_audit_status`,
- `oms_audit_remark`,
- `oms_callback_time`,
- `batch_no`,
- `oms_audit_time`,
- `status`
- from mall_goods_product
- WHERE 1=1
- <if test="mallGoodsProductSns != null">
- AND mall_goods_product_sn in
- <foreach item="id" collection="mallGoodsProductSns" open="(" separator="," close=")">
- #{id}
- </foreach>
- </if>
- </select>
- <select id="selectBySku" resultType="com.kmall.admin.entity.GoodsProductEntity">
- select
- `mall_goods_product_sn`,
- `merch_sn`,
- `third_merch_sn`,
- `prod_barcode`,
- `sku`,
- `cus_goods_code`,
- `prod_name`,
- `prod_ename`,
- `prod_record_name`,
- `prod_record_ename`,
- `ciq_prod_model`,
- `prod_brand`,
- `ori_cnt_code`,
- `unit_code`,
- `decl_price`,
- `decl_currency_code`,
- `supplier_name`,
- `supplier_cnt_code`,
- `prod_comp_name`,
- `prod_comp_cnt_code`,
- `ciq_main_ele`,
- `ciq_monitor_type`,
- `is_law`,
- `is_gift`,
- `cus_decl_ele`,
- `creater_sn`,
- `create_time`,
- `moder_sn`,
- `mod_time`,
- `tstm`,
- `ex_field`,
- `ex_field2`,
- `ex_field3`,
- `ex_field4`,
- `ex_field5`,
- `legal_unit1_qty`,
- `net_weight`,
- `legal_unit2_qty`,
- `gross_weight`,
- `local_ems_no`,
- `item_record_no`,
- `is_send`,
- `ems_class_code`,
- `up_img`,
- `down_img`,
- `left_img`,
- `right_img`,
- `before_img`,
- `after_img`,
- `send_time`,
- `oms_audit_status`,
- `oms_audit_remark`,
- `oms_callback_time`,
- `batch_no`,
- `oms_audit_time`,
- `status`
- from mall_goods_product
- where sku = #{sku}
- </select>
- <select id="selectByBarcode" resultType="com.kmall.admin.entity.GoodsProductEntity">
- select
- `mall_goods_product_sn`,
- `merch_sn`,
- `third_merch_sn`,
- `prod_barcode`,
- `sku`,
- `cus_goods_code`,
- `prod_name`,
- `prod_ename`,
- `prod_record_name`,
- `prod_record_ename`,
- `ciq_prod_model`,
- `prod_brand`,
- `ori_cnt_code`,
- `unit_code`,
- `decl_price`,
- `decl_currency_code`,
- `supplier_name`,
- `supplier_cnt_code`,
- `prod_comp_name`,
- `prod_comp_cnt_code`,
- `ciq_main_ele`,
- `ciq_monitor_type`,
- `is_law`,
- `is_gift`,
- `cus_decl_ele`,
- `creater_sn`,
- `create_time`,
- `moder_sn`,
- `mod_time`,
- `tstm`,
- `ex_field`,
- `ex_field2`,
- `ex_field3`,
- `ex_field4`,
- `ex_field5`,
- `legal_unit1_qty`,
- `net_weight`,
- `legal_unit2_qty`,
- `gross_weight`,
- `local_ems_no`,
- `item_record_no`,
- `is_send`,
- `ems_class_code`,
- `up_img`,
- `down_img`,
- `left_img`,
- `right_img`,
- `before_img`,
- `after_img`,
- `send_time`,
- `oms_audit_status`,
- `oms_audit_remark`,
- `oms_callback_time`,
- `batch_no`,
- `oms_audit_time`,
- `status`
- from mall_goods_product
- where prod_barcode = #{barCode}
- </select>
- <insert id="save" parameterType="com.kmall.admin.entity.GoodsProductEntity">
- insert into mall_goods_product
- <trim prefix="(" suffix=")" suffixOverrides="," >
- <if test="merchSn != null">`merch_sn` , </if>
- <if test="thirdMerchSn != null">`third_merch_sn` , </if>
- <if test="prodBarcode != null">`prod_barcode` , </if>
- <if test="sku != null">`sku` , </if>
- <if test="cusGoodsCode != null">`cus_goods_code` , </if>
- <if test="prodName != null">`prod_name` , </if>
- <if test="prodEname != null">`prod_ename` , </if>
- <if test="prodRecordName != null">`prod_record_name` , </if>
- <if test="prodRecordEname != null">`prod_record_ename` , </if>
- <if test="ciqProdModel != null">`ciq_prod_model` , </if>
- <if test="prodBrand != null">`prod_brand` , </if>
- <if test="oriCntCode != null">`ori_cnt_code` , </if>
- <if test="unitCode != null">`unit_code` , </if>
- <if test="declPrice != null">`decl_price` , </if>
- <if test="declCurrencyCode != null">`decl_currency_code` , </if>
- <if test="supplierName != null">`supplier_name` , </if>
- <if test="supplierCntCode != null">`supplier_cnt_code` , </if>
- <if test="prodCompName != null">`prod_comp_name` , </if>
- <if test="prodCompCntCode != null">`prod_comp_cnt_code` , </if>
- <if test="ciqMainEle != null">`ciq_main_ele` , </if>
- <if test="ciqMonitorType != null">`ciq_monitor_type` , </if>
- <if test="isLaw != null">`is_law` , </if>
- <if test="isGift != null">`is_gift` , </if>
- <if test="cusDeclEle != null">`cus_decl_ele` , </if>
- <if test="createrSn != null">`creater_sn` , </if>
- <if test="createTime != null">`create_time` , </if>
- <if test="moderSn != null">`moder_sn` , </if>
- <if test="modTime != null">`mod_time`, </if>
- <if test="tstm != null">`tstm` , </if>
- <if test="exField != null">`ex_field` , </if>
- <if test="exField2 != null">`ex_field2` , </if>
- <if test="exField3 != null">`ex_field3` , </if>
- <if test="exField4 != null">`ex_field4` , </if>
- <if test="exField5 != null">`ex_field5` , </if>
- <if test="legalUnit1Qty != null">`legal_unit1_qty` , </if>
- <if test="netWeight != null">`net_weight` , </if>
- <if test="legalUnit2Qty != null">`legal_unit2_qty` , </if>
- <if test="grossWeight != null">`gross_weight` , </if>
- <if test="localEmsNo != null">`local_ems_no` , </if>
- <if test="itemRecordNo != null">`item_record_no` , </if>
- `is_send` ,
- <if test="emsClassCode != null">`ems_class_code` ,</if>
- <if test="upImg != null">`up_img` ,</if>
- <if test="downImg != null">`down_img` ,</if>
- <if test="leftImg != null">`left_img` ,</if>
- <if test="rightImg != null">`right_img`,</if>
- <if test="beforeImg != null">`before_img` ,</if>
- <if test="afterImg != null">`after_img` ,</if>
- <if test="sendTime != null">`send_time` , </if>
- <if test="omsAuditStatus != null">`oms_audit_status` , </if>
- <if test="omsAuditRemark != null">`oms_audit_remark` , </if>
- <if test="omsAuditTime != null">`oms_audit_time`, </if>
- <if test="omsCallbackTime != null">`oms_callback_time`, </if>
- <if test="status != null">`status` , </if>
- </trim>
- <trim prefix="values (" suffix=")" suffixOverrides="," >
- <if test="merchSn != null">#{merchSn}, </if>
- <if test="thirdMerchSn != null"> #{thirdMerchSn}, </if>
- <if test="prodBarcode != null"> #{prodBarcode}, </if>
- <if test="sku != null"> #{sku}, </if>
- <if test="cusGoodsCode != null"> #{cusGoodsCode}, </if>
- <if test="prodName != null"> #{prodName}, </if>
- <if test="prodEname != null"> #{prodEname}, </if>
- <if test="prodRecordName != null">#{prodRecordName}, </if>
- <if test="prodRecordEname != null"> #{prodRecordEname}, </if>
- <if test="ciqProdModel != null"> #{ciqProdModel}, </if>
- <if test="prodBrand != null"> #{prodBrand}, </if>
- <if test="oriCntCode != null"> #{oriCntCode}, </if>
- <if test="unitCode != null"> #{unitCode}, </if>
- <if test="declPrice != null"> #{declPrice}, </if>
- <if test="declCurrencyCode != null"> #{declCurrencyCode}, </if>
- <if test="supplierName != null"> #{supplierName}, </if>
- <if test="supplierCntCode != null"> #{supplierCntCode}, </if>
- <if test="prodCompName != null"> #{prodCompName}, </if>
- <if test="prodCompCntCode != null"> #{prodCompCntCode}, </if>
- <if test="ciqMainEle != null">#{ciqMainEle}, </if>
- <if test="ciqMonitorType != null"> #{ciqMonitorType}, </if>
- <if test="isLaw != null"> #{isLaw}, </if>
- <if test="isGift != null"> #{isGift}, </if>
- <if test="cusDeclEle != null"> #{cusDeclEle}, </if>
- <if test="createrSn != null"> #{createrSn}, </if>
- <if test="createTime != null"> #{createTime}, </if>
- <if test="moderSn != null"> #{moderSn}, </if>
- <if test="modTime != null"> #{modTime}, </if>
- <if test="tstm != null"> #{tstm}, </if>
- <if test="exField != null"> #{exField}, </if>
- <if test="exField2 != null"> #{exField2}, </if>
- <if test="exField3 != null"> #{exField3}, </if>
- <if test="exField4 != null"> #{exField4}, </if>
- <if test="exField5 != null"> #{exField5}, </if>
- <if test="legalUnit1Qty != null"> #{legalUnit1Qty}, </if>
- <if test="netWeight != null"> #{netWeight}, </if>
- <if test="legalUnit2Qty != null"> #{legalUnit2Qty}, </if>
- <if test="grossWeight != null"> #{grossWeight}, </if>
- <if test="localEmsNo != null"> #{localEmsNo}, </if>
- <if test="itemRecordNo != null"> #{itemRecordNo}, </if>
- '0' ,
- <if test="emsClassCode != null"> #{emsClassCode},</if>
- <if test="upImg != null"> #{upImg},</if>
- <if test="downImg != null"> #{downImg},</if>
- <if test="leftImg != null"> #{leftImg},</if>
- <if test="rightImg != null"> #{rightImg},</if>
- <if test="beforeImg != null"> #{beforeImg},</if>
- <if test="afterImg != null"> #{afterImg},</if>
- <if test="sendTime != null"> #{sendTime}, </if>
- <if test="omsAuditStatus != null"> #{omsAuditStatus}, </if>
- <if test="omsAuditRemark != null"> #{omsAuditRemark}, </if>
- <if test="omsAuditTime != null"> #{omsAuditTime}, </if>
- <if test="omsCallbackTime != null"> #{omsCallbackTime}, </if>
- <if test="status != null"> #{status}, </if>
- </trim>
- </insert>
- <insert id="saveBatch" parameterType="java.util.List" useGeneratedKeys="true" keyProperty="id">
- insert into mall_goods_product(
- `merch_sn`,
- `third_merch_sn`,
- `prod_barcode`,
- `sku`,
- `batch_no`,
- `cus_goods_code`,
- `prod_name`,
- `prod_ename`,
- `prod_record_name`,
- `ciq_prod_model`,
- `prod_brand`,
- `ori_cnt_code`,
- `unit_code`,
- `decl_price`,
- `decl_currency_code`,
- `supplier_name`,
- `supplier_cnt_code`,
- `prod_comp_name`,
- `prod_comp_cnt_code`,
- `ciq_main_ele`,
- `ciq_monitor_type`,
- `is_law`,
- `is_gift`,
- `cus_decl_ele`,
- `creater_sn`,
- `create_time`,
- `net_weight`,
- `gross_weight`,
- `is_send`,
- `ems_class_code`,
- `status`
- )
- values
- <foreach collection="list" index="index" item="item" separator=",">
- (
- #{item.merchSn},
- #{item.thirdMerchSn},
- #{item.prodBarcode},
- #{item.sku},
- #{item.batchNo},
- #{item.cusGoodsCode},
- #{item.prodName},
- #{item.prodEname},
- #{item.prodRecordName},
- #{item.ciqProdModel},
- #{item.prodBrand},
- #{item.oriCntCode},
- #{item.unitCode},
- #{item.declPrice},
- #{item.declCurrencyCode},
- #{item.supplierName},
- #{item.supplierCntCode},
- #{item.prodCompName},
- #{item.prodCompCntCode},
- #{item.ciqMainEle},
- #{item.ciqMonitorType},
- #{item.isLaw},
- #{item.isGift},
- #{item.cusDeclEle},
- #{item.createrSn},
- #{item.createTime},
- #{item.netWeight},
- #{item.grossWeight},
- '0',
- #{item.emsClassCode},
- #{item.status}
- )
- </foreach>
- </insert>
- <update id="update" parameterType="com.kmall.admin.entity.GoodsProductEntity">
- update mall_goods_product
- <set>
- <if test="merchSn != null">`merch_sn` = #{merchSn}, </if>
- <if test="thirdMerchSn != null">`third_merch_sn` = #{thirdMerchSn}, </if>
- <if test="prodBarcode != null">`prod_barcode` = #{prodBarcode}, </if>
- <if test="sku != null">`sku` = #{sku}, </if>
- <if test="cusGoodsCode != null">`cus_goods_code` = #{cusGoodsCode}, </if>
- <if test="prodName != null">`prod_name` = #{prodName}, </if>
- <if test="prodEname != null">`prod_ename` = #{prodEname}, </if>
- <if test="prodRecordName != null">`prod_record_name` = #{prodRecordName}, </if>
- <if test="prodRecordEname != null">`prod_record_ename` = #{prodRecordEname}, </if>
- <if test="ciqProdModel != null">`ciq_prod_model` = #{ciqProdModel}, </if>
- <if test="prodBrand != null">`prod_brand` = #{prodBrand}, </if>
- <if test="oriCntCode != null">`ori_cnt_code` = #{oriCntCode}, </if>
- <if test="unitCode != null">`unit_code` = #{unitCode}, </if>
- <if test="declPrice != null">`decl_price` = #{declPrice}, </if>
- <if test="declCurrencyCode != null">`decl_currency_code` = #{declCurrencyCode}, </if>
- <if test="supplierName != null">`supplier_name` = #{supplierName}, </if>
- <if test="supplierCntCode != null">`supplier_cnt_code` = #{supplierCntCode}, </if>
- <if test="prodCompName != null">`prod_comp_name` = #{prodCompName}, </if>
- <if test="prodCompCntCode != null">`prod_comp_cnt_code` = #{prodCompCntCode}, </if>
- <if test="ciqMainEle != null">`ciq_main_ele` = #{ciqMainEle}, </if>
- <if test="ciqMonitorType != null">`ciq_monitor_type` = #{ciqMonitorType}, </if>
- <if test="isLaw != null">`is_law` = #{isLaw}, </if>
- <if test="isGift != null">`is_gift` = #{isGift}, </if>
- <if test="cusDeclEle != null">`cus_decl_ele` = #{cusDeclEle}, </if>
- <if test="createrSn != null">`creater_sn` = #{createrSn}, </if>
- <if test="createTime != null">`create_time` = #{createTime}, </if>
- <if test="moderSn != null">`moder_sn` = #{moderSn}, </if>
- <if test="modTime != null">`mod_time` = #{modTime}, </if>
- <if test="tstm != null">`tstm` = #{tstm}, </if>
- <if test="exField != null">`ex_field` = #{exField}, </if>
- <if test="exField2 != null">`ex_field2` = #{exField2}, </if>
- <if test="exField3 != null">`ex_field3` = #{exField3}, </if>
- <if test="exField4 != null">`ex_field4` = #{exField4}, </if>
- <if test="exField5 != null">`ex_field5` = #{exField5}, </if>
- <if test="legalUnit1Qty != null">`legal_unit1_qty` = #{legalUnit1Qty}, </if>
- <if test="netWeight != null">`net_weight` = #{netWeight}, </if>
- <if test="legalUnit2Qty != null">`legal_unit2_qty` = #{legalUnit2Qty}, </if>
- <if test="grossWeight != null">`gross_weight` = #{grossWeight}, </if>
- <if test="localEmsNo != null">`local_ems_no` = #{localEmsNo}, </if>
- <if test="itemRecordNo != null">`item_record_no` = #{itemRecordNo}, </if>
- <if test="isSend != null">`is_send` = #{isSend}, </if>
- <if test="emsClassCode != null">`ems_class_code` = #{emsClassCode},</if>
- <if test="upImg != null">`up_img` = #{upImg},</if>
- <if test="downImg != null">`down_img` = #{downImg},</if>
- <if test="leftImg != null">`left_img` = #{leftImg},</if>
- <if test="rightImg != null">`right_img` = #{rightImg},</if>
- <if test="beforeImg != null">`before_img` = #{beforeImg},</if>
- <if test="afterImg != null">`after_img` = #{afterImg},</if>
- <if test="sendTime != null">`send_time` = #{sendTime}, </if>
- <if test="omsAuditStatus != null">`oms_audit_status` = #{omsAuditStatus}, </if>
- <if test="omsAuditRemark != null">`oms_audit_remark` = #{omsAuditRemark}, </if>
- <if test="omsAuditTime != null">`oms_audit_time` = #{omsAuditTime}, </if>
- <if test="omsCallbackTime != null">`oms_callback_time` = #{omsCallbackTime}, </if>
- <if test="status != null">`status` = #{status}, </if>
- </set>
- where mall_goods_product_sn = #{mallGoodsProductSn}
- </update>
- <update id="updateBatch" parameterType="java.util.List">
- <foreach collection="list" item="item" index="index" open="" close="" separator=";">
- update mall_goods_product
- <set>
- <if test="item.merchSn != null">`merch_sn` = #{item.merchSn}, </if>
- <if test="item.thirdMerchSn != null">`third_merch_sn` = #{item.thirdMerchSn}, </if>
- <if test="item.prodBarcode != null">`prod_barcode` = #{item.prodBarcode}, </if>
- <if test="item.sku != null">`sku` = #{item.sku}, </if>
- <if test="item.cusGoodsCode != null">`cus_goods_code` = #{item.cusGoodsCode}, </if>
- <if test="item.prodName != null">`prod_name` = #{item.prodName}, </if>
- <if test="item.prodEname != null">`prod_ename` = #{item.prodEname}, </if>
- <if test="item.prodRecordName != null">`prod_record_name` = #{item.prodRecordName}, </if>
- <if test="item.prodRecordEname != null">`prod_record_ename` = #{item.prodRecordEname}, </if>
- <if test="item.ciqProdModel != null">`ciq_prod_model` = #{item.ciqProdModel}, </if>
- <if test="item.prodBrand != null">`prod_brand` = #{item.prodBrand}, </if>
- <if test="item.oriCntCode != null">`ori_cnt_code` = #{item.oriCntCode}, </if>
- <if test="item.unitCode != null">`unit_code` = #{item.unitCode}, </if>
- <if test="item.declPrice != null">`decl_price` = #{item.declPrice}, </if>
- <if test="item.declCurrencyCode != null">`decl_currency_code` = #{item.declCurrencyCode}, </if>
- <if test="item.supplierName != null">`supplier_name` = #{item.supplierName}, </if>
- <if test="item.supplierCntCode != null">`supplier_cnt_code` = #{item.supplierCntCode}, </if>
- <if test="item.prodCompName != null">`prod_comp_name` = #{item.prodCompName}, </if>
- <if test="item.prodCompCntCode != null">`prod_comp_cnt_code` = #{item.prodCompCntCode}, </if>
- <if test="item.ciqMainEle != null">`ciq_main_ele` = #{item.ciqMainEle}, </if>
- <if test="item.ciqMonitorType != null">`ciq_monitor_type` = #{item.ciqMonitorType}, </if>
- <if test="item.isLaw != null">`is_law` = #{item.isLaw}, </if>
- <if test="item.isGift != null">`is_gift` = #{item.isGift}, </if>
- <if test="item.cusDeclEle != null">`cus_decl_ele` = #{item.cusDeclEle}, </if>
- <if test="item.createrSn != null">`creater_sn` = #{item.createrSn}, </if>
- <if test="item.createTime != null">`create_time` = #{item.createTime}, </if>
- <if test="item.moderSn != null">`moder_sn` = #{item.moderSn}, </if>
- <if test="item.modTime != null">`mod_time` = #{item.modTime}, </if>
- <if test="item.tstm != null">`tstm` = #{item.tstm}, </if>
- <if test="item.exField != null">`ex_field` = #{item.exField}, </if>
- <if test="item.exField2 != null">`ex_field2` = #{item.exField2}, </if>
- <if test="item.exField3 != null">`ex_field3` = #{item.exField3}, </if>
- <if test="item.exField4 != null">`ex_field4` = #{item.exField4}, </if>
- <if test="item.exField5 != null">`ex_field5` = #{item.exField5}, </if>
- <if test="item.legalUnit1Qty != null">`legal_unit1_qty` = #{item.legalUnit1Qty}, </if>
- <if test="item.netWeight != null">`net_weight` = #{item.netWeight}, </if>
- <if test="item.legalUnit2Qty != null">`legal_unit2_qty` = #{item.legalUnit2Qty}, </if>
- <if test="item.grossWeight != null">`gross_weight` = #{item.grossWeight}, </if>
- <if test="item.localEmsNo != null">`local_ems_no` = #{item.localEmsNo}, </if>
- <if test="item.itemRecordNo != null">`item_record_no` = #{item.itemRecordNo}, </if>
- <if test="item.isSend != null">`is_send` = #{item.isSend}, </if>
- <if test="item.emsClassCode != null">`ems_class_code` = #{item.emsClassCode},</if>
- <if test="item.upImg != null">`up_img` = #{item.upImg},</if>
- <if test="item.downImg != null">`down_img` = #{item.downImg},</if>
- <if test="item.leftImg != null">`left_img` = #{item.leftImg},</if>
- <if test="item.rightImg != null">`right_img` = #{item.rightImg},</if>
- <if test="item.beforeImg != null">`before_img` = #{item.beforeImg},</if>
- <if test="item.afterImg != null">`after_img` = #{item.afterImg},</if>
- <if test="item.sendTime != null">`send_time` = #{item.sendTime}, </if>
- <if test="item.omsAuditStatus != null">`oms_audit_status` = #{item.omsAuditStatus}, </if>
- <if test="item.omsAuditRemark != null">`oms_audit_remark` = #{item.omsAuditRemark}, </if>
- <if test="item.omsAuditTime != null">`oms_audit_time` = #{item.omsAuditTime}, </if>
- <if test="item.omsCallbackTime != null">`oms_callback_time` = #{item.omsCallbackTime}, </if>
- <if test="item.status != null">`status` = #{item.status}, </if>
- </set>
- where mall_goods_product_sn = #{item.mallGoodsProductSn}
- </foreach>
- </update>
- <update id="updateStatusBySkuBatch" parameterType="map">
- update mall_goods_product
- <set>
- <if test="map.isLaw != null">`is_law` = #{map.isLaw}, </if>
- <if test="map.isGift != null">`is_gift` = #{map.isGift}, </if>
- <if test="map.moderSn != null">`moder_sn` = #{map.moderSn}, </if>
- <if test="map.modTime != null">`mod_time` = #{map.modTime}, </if>
- <if test="map.tstm != null">`tstm` = #{map.tstm}, </if>
- <if test="map.exField != null">`ex_field` = #{map.exField}, </if>
- <if test="map.exField2 != null">`ex_field2` = #{map.exField2}, </if>
- <if test="map.exField3 != null">`ex_field3` = #{map.exField3}, </if>
- <if test="map.exField4 != null">`ex_field4` = #{map.exField4}, </if>
- <if test="map.exField5 != null">`ex_field5` = #{map.exField5}, </if>
- <if test="map.isSend != null">`is_send` = #{map.isSend}, </if>
- <if test="map.sendTime != null">`send_time` = #{map.sendTime}, </if>
- <if test="map.omsAuditStatus != null">`oms_audit_status` = #{map.omsAuditStatus}, </if>
- <if test="map.omsAuditRemark != null">`oms_audit_remark` = #{map.omsAuditRemark}, </if>
- <if test="map.omsAuditTime != null">`oms_audit_time` = #{map.omsAuditTime}, </if>
- <if test="map.omsCallbackTime != null">`oms_callback_time` = #{map.omsCallbackTime}, </if>
- <if test="map.status != null">`status` = #{map.status}, </if>
- <if test="map.updateStatusMode != null and map.updateStatusMode == 1 ">
- `status` =
- <if test="map.isSend == 1">
- case status
- when '00' then '02'
- when '01' then '02'
- when '10' then '12'
- when '11' then '12'
- else '99' end
- </if>
- <if test="map.isSend == 2">
- case status
- when '00' then '01'
- when '01' then '01'
- when '10' then '11'
- when '11' then '11'
- else '99' end
- </if>
- ,
- </if>
- <if test="map.updateStatusMode != null and map.updateStatusMode == 2 ">
- `status` =
- <if test="map.omsAuditStatus == 2">
- case status
- when '02' then '21'
- when '12' then '21'
- else '88' end
- </if>
- <if test="map.omsAuditStatus == 3">
- case status
- when '02' then '03'
- when '12' then '13'
- else '88' end
- </if>
- ,
- </if>
- </set>
- where sku in
- <foreach collection="list" item="sku" open="(" separator="," close=")">
- #{sku}
- </foreach>
- </update>
- <delete id="delete">
- delete from mall_goods_product where mall_goods_product_sn = #{value}
- </delete>
- <delete id="deleteBatch">
- delete from mall_goods_product where mall_goods_product_sn in
- <foreach item="mallGoodsProductSn" collection="array" open="(" separator="," close=")">
- #{mallGoodsProductSn}
- </foreach>
- </delete>
- </mapper>
|