增加批次商品选择

This commit is contained in:
季圣华
2021-09-29 01:17:20 +08:00
parent 45adbe85e9
commit ef30a7cc3b
15 changed files with 419 additions and 34 deletions

View File

@@ -4,6 +4,7 @@
<resultMap id="BaseResultMap" type="com.jsh.erp.datasource.entities.SerialNumber">
<id column="id" jdbcType="BIGINT" property="id" />
<result column="material_id" jdbcType="BIGINT" property="materialId" />
<result column="depot_id" jdbcType="BIGINT" property="depotId" />
<result column="serial_number" jdbcType="VARCHAR" property="serialNumber" />
<result column="is_sell" jdbcType="VARCHAR" property="isSell" />
<result column="remark" jdbcType="VARCHAR" property="remark" />
@@ -74,8 +75,8 @@
</where>
</sql>
<sql id="Base_Column_List">
id, material_id, serial_number, is_sell, remark, delete_flag, create_time, creator,
update_time, updater, depot_head_id, tenant_id
id, material_id, depot_id, serial_number, is_sell, remark, delete_flag, create_time,
creator, update_time, updater, depot_head_id, tenant_id
</sql>
<select id="selectByExample" parameterType="com.jsh.erp.datasource.entities.SerialNumberExample" resultMap="BaseResultMap">
select
@@ -108,16 +109,16 @@
</if>
</delete>
<insert id="insert" parameterType="com.jsh.erp.datasource.entities.SerialNumber">
insert into jsh_serial_number (id, material_id, serial_number,
is_sell, remark, delete_flag,
create_time, creator, update_time,
updater, depot_head_id, tenant_id
)
values (#{id,jdbcType=BIGINT}, #{materialId,jdbcType=BIGINT}, #{serialNumber,jdbcType=VARCHAR},
#{isSell,jdbcType=VARCHAR}, #{remark,jdbcType=VARCHAR}, #{deleteFlag,jdbcType=VARCHAR},
#{createTime,jdbcType=TIMESTAMP}, #{creator,jdbcType=BIGINT}, #{updateTime,jdbcType=TIMESTAMP},
#{updater,jdbcType=BIGINT}, #{depotHeadId,jdbcType=BIGINT}, #{tenantId,jdbcType=BIGINT}
)
insert into jsh_serial_number (id, material_id, depot_id,
serial_number, is_sell, remark,
delete_flag, create_time, creator,
update_time, updater, depot_head_id,
tenant_id)
values (#{id,jdbcType=BIGINT}, #{materialId,jdbcType=BIGINT}, #{depotId,jdbcType=BIGINT},
#{serialNumber,jdbcType=VARCHAR}, #{isSell,jdbcType=VARCHAR}, #{remark,jdbcType=VARCHAR},
#{deleteFlag,jdbcType=VARCHAR}, #{createTime,jdbcType=TIMESTAMP}, #{creator,jdbcType=BIGINT},
#{updateTime,jdbcType=TIMESTAMP}, #{updater,jdbcType=BIGINT}, #{depotHeadId,jdbcType=BIGINT},
#{tenantId,jdbcType=BIGINT})
</insert>
<insert id="insertSelective" parameterType="com.jsh.erp.datasource.entities.SerialNumber">
insert into jsh_serial_number
@@ -128,6 +129,9 @@
<if test="materialId != null">
material_id,
</if>
<if test="depotId != null">
depot_id,
</if>
<if test="serialNumber != null">
serial_number,
</if>
@@ -166,6 +170,9 @@
<if test="materialId != null">
#{materialId,jdbcType=BIGINT},
</if>
<if test="depotId != null">
#{depotId,jdbcType=BIGINT},
</if>
<if test="serialNumber != null">
#{serialNumber,jdbcType=VARCHAR},
</if>
@@ -213,6 +220,9 @@
<if test="record.materialId != null">
material_id = #{record.materialId,jdbcType=BIGINT},
</if>
<if test="record.depotId != null">
depot_id = #{record.depotId,jdbcType=BIGINT},
</if>
<if test="record.serialNumber != null">
serial_number = #{record.serialNumber,jdbcType=VARCHAR},
</if>
@@ -252,6 +262,7 @@
update jsh_serial_number
set id = #{record.id,jdbcType=BIGINT},
material_id = #{record.materialId,jdbcType=BIGINT},
depot_id = #{record.depotId,jdbcType=BIGINT},
serial_number = #{record.serialNumber,jdbcType=VARCHAR},
is_sell = #{record.isSell,jdbcType=VARCHAR},
remark = #{record.remark,jdbcType=VARCHAR},
@@ -272,6 +283,9 @@
<if test="materialId != null">
material_id = #{materialId,jdbcType=BIGINT},
</if>
<if test="depotId != null">
depot_id = #{depotId,jdbcType=BIGINT},
</if>
<if test="serialNumber != null">
serial_number = #{serialNumber,jdbcType=VARCHAR},
</if>
@@ -308,6 +322,7 @@
<update id="updateByPrimaryKey" parameterType="com.jsh.erp.datasource.entities.SerialNumber">
update jsh_serial_number
set material_id = #{materialId,jdbcType=BIGINT},
depot_id = #{depotId,jdbcType=BIGINT},
serial_number = #{serialNumber,jdbcType=VARCHAR},
is_sell = #{isSell,jdbcType=VARCHAR},
remark = #{remark,jdbcType=VARCHAR},