This commit is contained in:
linfso 2024-04-17 15:46:17 +08:00
parent 9525eae731
commit f8524525b0
2 changed files with 31 additions and 51 deletions

View File

@ -1,10 +1,10 @@
/**
/**
* @Project: emis
* @Title: EmisGoods.java
* @author linfso
* @date 2024-01-10 03:59:32
* @date 2024-04-17 07:45:04
* @Copyright: ShangHai Duta 2022 All rights reserved.
* @version v1.0
* @version v1.0
* @Description: <p> 货物信息 实体类 </p>
*/
@ -17,6 +17,7 @@ import com.xdadan.erp.common.annotation.Excel;
import com.xdadan.erp.common.core.domain.BaseEntity;
import com.xdadan.erp.common.core.domain.TreeEntity;
import java.io.Serializable;
import java.math.BigDecimal;
import java.util.Date;
import lombok.Data;
@ -25,9 +26,9 @@ import lombok.Data;
* @ClassName EmisGoods
* @Description 货物信息
* @author linfso
* @date 2024-01-10 03:59:32
* @date 2024-04-17 07:45:04
*/
@Data
@Data
public class EmisGoods extends BaseEntity
{
private static final long serialVersionUID = 1L;
@ -50,6 +51,10 @@ public class EmisGoods extends BaseEntity
private String barcode;
/* 原产国 */
private String orginalNation;
/* 图片地址 */
private String picUrl;
/* 归属客户 */
private String ownerId;
/* 是否实物 0-否 1-是 */
private Integer isRealGoods;
/* 是否大类 0-否 1-是 */
@ -134,15 +139,5 @@ public class EmisGoods extends BaseEntity
private String saleUrl;
/* 口岸编码 */
private String portCode;
/* ext1 */
private String ext1;
/* ext2 */
private String ext2;
/* ext3 */
private String ext3;
/* ext4 */
private String ext4;
/* ext5 */
private String ext5;
}

View File

@ -1,9 +1,9 @@
<?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">
PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="com.xdadan.erp.emis.mapper.EmisGoodsMapper">
<resultMap type="EmisGoods" id="EmisGoodsResult">
<result property="id" column="id" />
<result property="goodsSn" column="goods_sn" />
@ -14,6 +14,8 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<result property="goodsModel" column="goods_model" />
<result property="barcode" column="barcode" />
<result property="orginalNation" column="orginal_nation" />
<result property="picUrl" column="pic_url" />
<result property="ownerId" column="owner_id" />
<result property="isRealGoods" column="is_real_goods" />
<result property="isBigCat" column="is_big_cat" />
<result property="brandId" column="brand_id" />
@ -56,11 +58,6 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<result property="pd" column="pd" />
<result property="saleUrl" column="sale_url" />
<result property="portCode" column="port_code" />
<result property="ext1" column="ext1" />
<result property="ext2" column="ext2" />
<result property="ext3" column="ext3" />
<result property="ext4" column="ext4" />
<result property="ext5" column="ext5" />
<result property="remark" column="remark" />
<result property="tenantId" column="tenant_id" />
<result property="delFlag" column="del_flag" />
@ -71,12 +68,12 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
</resultMap>
<sql id="selectEmisGoodsVo">
select id, goods_sn, goods_name, goods_name_en, goods_cat, goods_type, goods_model, barcode, orginal_nation, is_real_goods, is_big_cat, brand_id, brand, net_weight, gross_weight, single_volume, single_length, single_width, single_height, pkg_pcs, pkg_volume, pkg_length, pkg_width, pkg_height, hs_code, is_code, unit, unit1, unit2, price, currency_type, rule_nation, manuf_enterprise, ebc_code, ciq_code, function, ingredients, purpose, product_validity, cebp_mode, supplier, serial_number, status, status_message, goods_sn2, goods_no2, lic_no, material_path, pd, sale_url, port_code, ext1, ext2, ext3, ext4, ext5, remark, tenant_id, del_flag, create_by, create_time, update_by, update_time from emis_goods
select id, goods_sn, goods_name, goods_name_en, goods_cat, goods_type, goods_model, barcode, orginal_nation, pic_url, owner_id, is_real_goods, is_big_cat, brand_id, brand, net_weight, gross_weight, single_volume, single_length, single_width, single_height, pkg_pcs, pkg_volume, pkg_length, pkg_width, pkg_height, hs_code, is_code, unit, unit1, unit2, price, currency_type, rule_nation, manuf_enterprise, ebc_code, ciq_code, function, ingredients, purpose, product_validity, cebp_mode, supplier, serial_number, status, status_message, goods_sn2, goods_no2, lic_no, material_path, pd, sale_url, port_code, remark, tenant_id, del_flag, create_by, create_time, update_by, update_time from emis_goods
</sql>
<select id="selectEmisGoodsList" parameterType="EmisGoods" resultMap="EmisGoodsResult">
<include refid="selectEmisGoodsVo"/>
<where>
<where>
<if test="id != null "> and id = #{id}</if>
<if test="goodsSn != null and goodsSn != ''"> and goods_sn like concat('%', #{goodsSn}, '%')</if>
<if test="goodsName != null and goodsName != ''"> and goods_name like concat('%', #{goodsName}, '%')</if>
@ -86,6 +83,8 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if test="goodsModel != null and goodsModel != ''"> and goods_model like concat('%', #{goodsModel}, '%')</if>
<if test="barcode != null and barcode != ''"> and barcode like concat('%', #{barcode}, '%')</if>
<if test="orginalNation != null and orginalNation != ''"> and orginal_nation like concat('%', #{orginalNation}, '%')</if>
<if test="picUrl != null and picUrl != ''"> and pic_url like concat('%', #{picUrl}, '%')</if>
<if test="ownerId != null and ownerId != ''"> and owner_id like concat('%', #{ownerId}, '%')</if>
<if test="isRealGoods != null "> and is_real_goods = #{isRealGoods}</if>
<if test="isBigCat != null "> and is_big_cat = #{isBigCat}</if>
<if test="brandId != null and brandId != ''"> and brand_id like concat('%', #{brandId}, '%')</if>
@ -128,11 +127,6 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if test="pd != null and pd != ''"> and pd like concat('%', #{pd}, '%')</if>
<if test="saleUrl != null and saleUrl != ''"> and sale_url like concat('%', #{saleUrl}, '%')</if>
<if test="portCode != null and portCode != ''"> and port_code like concat('%', #{portCode}, '%')</if>
<if test="ext1 != null and ext1 != ''"> and ext1 like concat('%', #{ext1}, '%')</if>
<if test="ext2 != null and ext2 != ''"> and ext2 like concat('%', #{ext2}, '%')</if>
<if test="ext3 != null and ext3 != ''"> and ext3 like concat('%', #{ext3}, '%')</if>
<if test="ext4 != null and ext4 != ''"> and ext4 like concat('%', #{ext4}, '%')</if>
<if test="ext5 != null and ext5 != ''"> and ext5 like concat('%', #{ext5}, '%')</if>
<if test="remark != null and remark != ''"> and remark like concat('%', #{remark}, '%')</if>
<if test="tenantId != null and tenantId != ''"> and tenant_id like concat('%', #{tenantId}, '%')</if>
<if test="delFlag != null and delFlag != ''"> and del_flag like concat('%', #{delFlag}, '%')</if>
@ -143,13 +137,13 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
</where>
order by create_time desc
</select>
<select id="selectEmisGoodsById" parameterType="Long" resultMap="EmisGoodsResult">
select id, goods_sn, goods_name, goods_name_en, goods_cat, goods_type, goods_model, barcode, orginal_nation, is_real_goods, is_big_cat, brand_id, brand, net_weight, gross_weight, single_volume, single_length, single_width, single_height, pkg_pcs, pkg_volume, pkg_length, pkg_width, pkg_height, hs_code, is_code, unit, unit1, unit2, price, currency_type, rule_nation, manuf_enterprise, ebc_code, ciq_code, function, ingredients, purpose, product_validity, cebp_mode, supplier, serial_number, status, status_message, goods_sn2, goods_no2, lic_no, material_path, pd, sale_url, port_code, ext1, ext2, ext3, ext4, ext5, remark, tenant_id, del_flag, create_by, create_time, update_by, update_time
select id, goods_sn, goods_name, goods_name_en, goods_cat, goods_type, goods_model, barcode, orginal_nation, pic_url, owner_id, is_real_goods, is_big_cat, brand_id, brand, net_weight, gross_weight, single_volume, single_length, single_width, single_height, pkg_pcs, pkg_volume, pkg_length, pkg_width, pkg_height, hs_code, is_code, unit, unit1, unit2, price, currency_type, rule_nation, manuf_enterprise, ebc_code, ciq_code, function, ingredients, purpose, product_validity, cebp_mode, supplier, serial_number, status, status_message, goods_sn2, goods_no2, lic_no, material_path, pd, sale_url, port_code, remark, tenant_id, del_flag, create_by, create_time, update_by, update_time
from emis_goods a
where a.id = #{id}
</select>
<insert id="insertEmisGoods" parameterType="EmisGoods">
insert into emis_goods
<trim prefix="(" suffix=")" suffixOverrides=",">
@ -162,6 +156,8 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if test="goodsModel != null and goodsModel != ''">goods_model,</if>
<if test="barcode != null and barcode != ''">barcode,</if>
<if test="orginalNation != null and orginalNation != ''">orginal_nation,</if>
<if test="picUrl != null and picUrl != ''">pic_url,</if>
<if test="ownerId != null and ownerId != ''">owner_id,</if>
<if test="isRealGoods != null">is_real_goods,</if>
<if test="isBigCat != null">is_big_cat,</if>
<if test="brandId != null and brandId != ''">brand_id,</if>
@ -204,11 +200,6 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if test="pd != null and pd != ''">pd,</if>
<if test="saleUrl != null and saleUrl != ''">sale_url,</if>
<if test="portCode != null and portCode != ''">port_code,</if>
<if test="ext1 != null and ext1 != ''">ext1,</if>
<if test="ext2 != null and ext2 != ''">ext2,</if>
<if test="ext3 != null and ext3 != ''">ext3,</if>
<if test="ext4 != null and ext4 != ''">ext4,</if>
<if test="ext5 != null and ext5 != ''">ext5,</if>
<if test="remark != null and remark != ''">remark,</if>
<if test="tenantId != null and tenantId != ''">tenant_id,</if>
<if test="delFlag != null and delFlag != ''">del_flag,</if>
@ -216,7 +207,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if test="createTime != null">create_time,</if>
<if test="updateBy != null and updateBy != ''">update_by,</if>
<if test="updateTime != null">update_time,</if>
</trim>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides=",">
<if test="id != null">#{id},</if>
<if test="goodsSn != null and goodsSn != ''">#{goodsSn},</if>
@ -227,6 +218,8 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if test="goodsModel != null and goodsModel != ''">#{goodsModel},</if>
<if test="barcode != null and barcode != ''">#{barcode},</if>
<if test="orginalNation != null and orginalNation != ''">#{orginalNation},</if>
<if test="picUrl != null and picUrl != ''">#{picUrl},</if>
<if test="ownerId != null and ownerId != ''">#{ownerId},</if>
<if test="isRealGoods != null">#{isRealGoods},</if>
<if test="isBigCat != null">#{isBigCat},</if>
<if test="brandId != null and brandId != ''">#{brandId},</if>
@ -269,11 +262,6 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if test="pd != null and pd != ''">#{pd},</if>
<if test="saleUrl != null and saleUrl != ''">#{saleUrl},</if>
<if test="portCode != null and portCode != ''">#{portCode},</if>
<if test="ext1 != null and ext1 != ''">#{ext1},</if>
<if test="ext2 != null and ext2 != ''">#{ext2},</if>
<if test="ext3 != null and ext3 != ''">#{ext3},</if>
<if test="ext4 != null and ext4 != ''">#{ext4},</if>
<if test="ext5 != null and ext5 != ''">#{ext5},</if>
<if test="remark != null and remark != ''">#{remark},</if>
<if test="tenantId != null and tenantId != ''">#{tenantId},</if>
<if test="delFlag != null and delFlag != ''">#{delFlag},</if>
@ -281,7 +269,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if test="createTime != null">#{createTime},</if>
<if test="updateBy != null and updateBy != ''">#{updateBy},</if>
<if test="updateTime != null">#{updateTime},</if>
</trim>
</trim>
</insert>
<update id="updateEmisGoods" parameterType="EmisGoods">
@ -295,6 +283,8 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if test="goodsModel != null and goodsModel != ''">goods_model = #{goodsModel},</if>
<if test="barcode != null and barcode != ''">barcode = #{barcode},</if>
<if test="orginalNation != null and orginalNation != ''">orginal_nation = #{orginalNation},</if>
<if test="picUrl != null and picUrl != ''">pic_url = #{picUrl},</if>
<if test="ownerId != null and ownerId != ''">owner_id = #{ownerId},</if>
<if test="isRealGoods != null">is_real_goods = #{isRealGoods},</if>
<if test="isBigCat != null">is_big_cat = #{isBigCat},</if>
<if test="brandId != null and brandId != ''">brand_id = #{brandId},</if>
@ -337,11 +327,6 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
<if test="pd != null and pd != ''">pd = #{pd},</if>
<if test="saleUrl != null and saleUrl != ''">sale_url = #{saleUrl},</if>
<if test="portCode != null and portCode != ''">port_code = #{portCode},</if>
<if test="ext1 != null and ext1 != ''">ext1 = #{ext1},</if>
<if test="ext2 != null and ext2 != ''">ext2 = #{ext2},</if>
<if test="ext3 != null and ext3 != ''">ext3 = #{ext3},</if>
<if test="ext4 != null and ext4 != ''">ext4 = #{ext4},</if>
<if test="ext5 != null and ext5 != ''">ext5 = #{ext5},</if>
<if test="remark != null and remark != ''">remark = #{remark},</if>
<if test="tenantId != null and tenantId != ''">tenant_id = #{tenantId},</if>
<if test="delFlag != null and delFlag != ''">del_flag = #{delFlag},</if>
@ -358,7 +343,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
</delete>
<delete id="deleteEmisGoodsByIds" parameterType="String">
delete from emis_goods where id in
delete from emis_goods where id in
<foreach item="id" collection="array" open="(" separator="," close=")">
#{id}
</foreach>