1.修改字段命名
parent
16acbbed33
commit
e3f7321a5e
@ -1,136 +1,141 @@
|
|||||||
<?xml version="1.0" encoding="UTF-8"?>
|
<?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">
|
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||||
<mapper namespace="com.glxp.sale.admin.dao.inventory.InvCountCodesMapper">
|
<mapper namespace="com.glxp.api.admin.dao.inventory.InvCountCodesDao">
|
||||||
<resultMap id="BaseResultMap" type="com.glxp.sale.admin.entity.inventory.InvCountCodes">
|
<resultMap id="BaseResultMap" type="com.glxp.api.admin.entity.inventory.InvCountCodes">
|
||||||
<!--@mbg.generated-->
|
<id column="id" jdbcType="INTEGER" property="id"/>
|
||||||
<!--@Table inv_count_codes-->
|
<result column="orderIdFk" jdbcType="VARCHAR" property="orderIdFk"/>
|
||||||
<id column="id" jdbcType="INTEGER" property="id" />
|
<result column="productId" jdbcType="VARCHAR" property="productId"/>
|
||||||
<result column="orderIdFk" jdbcType="VARCHAR" property="orderidfk" />
|
<result column="code" jdbcType="VARCHAR" property="code"/>
|
||||||
<result column="productId" jdbcType="VARCHAR" property="productid" />
|
<result column="status" jdbcType="BOOLEAN" property="status"/>
|
||||||
<result column="code" jdbcType="VARCHAR" property="code" />
|
</resultMap>
|
||||||
<result column="status" jdbcType="BOOLEAN" property="status" />
|
|
||||||
</resultMap>
|
<sql id="Base_Column_List">
|
||||||
<sql id="Base_Column_List">
|
id,
|
||||||
<!--@mbg.generated-->
|
|
||||||
id, orderIdFk, productId, code, `status`
|
|
||||||
</sql>
|
|
||||||
<select id="selectByPrimaryKey" parameterType="java.lang.Integer" resultMap="BaseResultMap">
|
|
||||||
<!--@mbg.generated-->
|
|
||||||
select
|
|
||||||
<include refid="Base_Column_List" />
|
|
||||||
from inv_count_codes
|
|
||||||
where id = #{id,jdbcType=INTEGER}
|
|
||||||
</select>
|
|
||||||
<delete id="deleteByPrimaryKey" parameterType="java.lang.Integer">
|
|
||||||
<!--@mbg.generated-->
|
|
||||||
delete from inv_count_codes
|
|
||||||
where id = #{id,jdbcType=INTEGER}
|
|
||||||
</delete>
|
|
||||||
<insert id="insert" keyColumn="id" keyProperty="id" parameterType="com.glxp.sale.admin.entity.inventory.InvCountCodes" useGeneratedKeys="true">
|
|
||||||
<!--@mbg.generated-->
|
|
||||||
insert into inv_count_codes (orderIdFk, productId, code,
|
|
||||||
`status`)
|
|
||||||
values (#{orderidfk,jdbcType=VARCHAR}, #{productid,jdbcType=VARCHAR}, #{code,jdbcType=VARCHAR},
|
|
||||||
#{status,jdbcType=BOOLEAN})
|
|
||||||
</insert>
|
|
||||||
<insert id="insertSelective" keyColumn="id" keyProperty="id" parameterType="com.glxp.sale.admin.entity.inventory.InvCountCodes" useGeneratedKeys="true">
|
|
||||||
<!--@mbg.generated-->
|
|
||||||
insert into inv_count_codes
|
|
||||||
<trim prefix="(" suffix=")" suffixOverrides=",">
|
|
||||||
<if test="orderidfk != null">
|
|
||||||
orderIdFk,
|
orderIdFk,
|
||||||
</if>
|
|
||||||
<if test="productid != null">
|
|
||||||
productId,
|
productId,
|
||||||
</if>
|
|
||||||
<if test="code != null">
|
|
||||||
code,
|
code,
|
||||||
</if>
|
`status`
|
||||||
<if test="status != null">
|
</sql>
|
||||||
`status`,
|
|
||||||
</if>
|
<select id="selectByPrimaryKey" parameterType="java.lang.Integer" resultMap="BaseResultMap">
|
||||||
</trim>
|
select
|
||||||
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
<include refid="Base_Column_List"/>
|
||||||
<if test="orderidfk != null">
|
from inv_count_codes
|
||||||
#{orderidfk,jdbcType=VARCHAR},
|
where id = #{id,jdbcType=INTEGER}
|
||||||
</if>
|
</select>
|
||||||
<if test="productid != null">
|
|
||||||
#{productid,jdbcType=VARCHAR},
|
<delete id="deleteByPrimaryKey" parameterType="java.lang.Integer">
|
||||||
</if>
|
delete
|
||||||
<if test="code != null">
|
from inv_count_codes
|
||||||
#{code,jdbcType=VARCHAR},
|
where id = #{id,jdbcType=INTEGER}
|
||||||
</if>
|
</delete>
|
||||||
<if test="status != null">
|
|
||||||
#{status,jdbcType=BOOLEAN},
|
<insert id="insert" keyColumn="id" keyProperty="id"
|
||||||
</if>
|
parameterType="com.glxp.api.admin.entity.inventory.InvCountCodes" useGeneratedKeys="true">
|
||||||
</trim>
|
insert into inv_count_codes (orderIdFk, productId, code,
|
||||||
</insert>
|
`status`)
|
||||||
<update id="updateByPrimaryKeySelective" parameterType="com.glxp.sale.admin.entity.inventory.InvCountCodes">
|
values (#{orderIdFk,jdbcType=VARCHAR}, #{productId,jdbcType=VARCHAR}, #{code,jdbcType=VARCHAR},
|
||||||
<!--@mbg.generated-->
|
#{status,jdbcType=BOOLEAN})
|
||||||
update inv_count_codes
|
</insert>
|
||||||
<set>
|
|
||||||
<if test="orderidfk != null">
|
<insert id="insertSelective" keyColumn="id" keyProperty="id"
|
||||||
orderIdFk = #{orderidfk,jdbcType=VARCHAR},
|
parameterType="com.glxp.api.admin.entity.inventory.InvCountCodes" useGeneratedKeys="true">
|
||||||
</if>
|
insert into inv_count_codes
|
||||||
<if test="productid != null">
|
<trim prefix="(" suffix=")" suffixOverrides=",">
|
||||||
productId = #{productid,jdbcType=VARCHAR},
|
<if test="orderIdFk != null">
|
||||||
</if>
|
orderIdFk,
|
||||||
<if test="code != null">
|
</if>
|
||||||
code = #{code,jdbcType=VARCHAR},
|
<if test="productId != null">
|
||||||
</if>
|
productId,
|
||||||
<if test="status != null">
|
</if>
|
||||||
`status` = #{status,jdbcType=BOOLEAN},
|
<if test="code != null">
|
||||||
</if>
|
code,
|
||||||
</set>
|
</if>
|
||||||
where id = #{id,jdbcType=INTEGER}
|
<if test="status != null">
|
||||||
</update>
|
`status`,
|
||||||
<update id="updateByPrimaryKey" parameterType="com.glxp.sale.admin.entity.inventory.InvCountCodes">
|
</if>
|
||||||
<!--@mbg.generated-->
|
</trim>
|
||||||
update inv_count_codes
|
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
||||||
set orderIdFk = #{orderidfk,jdbcType=VARCHAR},
|
<if test="orderIdFk != null">
|
||||||
productId = #{productid,jdbcType=VARCHAR},
|
#{orderIdFk,jdbcType=VARCHAR},
|
||||||
code = #{code,jdbcType=VARCHAR},
|
</if>
|
||||||
`status` = #{status,jdbcType=BOOLEAN}
|
<if test="productId != null">
|
||||||
where id = #{id,jdbcType=INTEGER}
|
#{productId,jdbcType=VARCHAR},
|
||||||
</update>
|
</if>
|
||||||
<update id="updateBatch" parameterType="java.util.List">
|
<if test="code != null">
|
||||||
<!--@mbg.generated-->
|
#{code,jdbcType=VARCHAR},
|
||||||
update inv_count_codes
|
</if>
|
||||||
<trim prefix="set" suffixOverrides=",">
|
<if test="status != null">
|
||||||
<trim prefix="orderIdFk = case" suffix="end,">
|
#{status,jdbcType=BOOLEAN},
|
||||||
<foreach collection="list" index="index" item="item">
|
</if>
|
||||||
when id = #{item.id,jdbcType=INTEGER} then #{item.orderidfk,jdbcType=VARCHAR}
|
</trim>
|
||||||
|
</insert>
|
||||||
|
|
||||||
|
<update id="updateByPrimaryKeySelective" parameterType="com.glxp.api.admin.entity.inventory.InvCountCodes">
|
||||||
|
update inv_count_codes
|
||||||
|
<set>
|
||||||
|
<if test="orderIdFk != null">
|
||||||
|
orderIdFk = #{orderIdFk,jdbcType=VARCHAR},
|
||||||
|
</if>
|
||||||
|
<if test="productId != null">
|
||||||
|
productId = #{productId,jdbcType=VARCHAR},
|
||||||
|
</if>
|
||||||
|
<if test="code != null">
|
||||||
|
code = #{code,jdbcType=VARCHAR},
|
||||||
|
</if>
|
||||||
|
<if test="status != null">
|
||||||
|
`status` = #{status,jdbcType=BOOLEAN},
|
||||||
|
</if>
|
||||||
|
</set>
|
||||||
|
where id = #{id,jdbcType=INTEGER}
|
||||||
|
</update>
|
||||||
|
|
||||||
|
<update id="updateByPrimaryKey" parameterType="com.glxp.api.admin.entity.inventory.InvCountCodes">
|
||||||
|
update inv_count_codes
|
||||||
|
set orderIdFk = #{orderIdFk,jdbcType=VARCHAR},
|
||||||
|
productId = #{productId,jdbcType=VARCHAR},
|
||||||
|
code = #{code,jdbcType=VARCHAR},
|
||||||
|
`status` = #{status,jdbcType=BOOLEAN}
|
||||||
|
where id = #{id,jdbcType=INTEGER}
|
||||||
|
</update>
|
||||||
|
|
||||||
|
<update id="updateBatch" parameterType="java.util.List">
|
||||||
|
update inv_count_codes
|
||||||
|
<trim prefix="set" suffixOverrides=",">
|
||||||
|
<trim prefix="orderIdFk = case" suffix="end,">
|
||||||
|
<foreach collection="list" index="index" item="item">
|
||||||
|
when id = #{item.id,jdbcType=INTEGER} then #{item.orderIdFk,jdbcType=VARCHAR}
|
||||||
|
</foreach>
|
||||||
|
</trim>
|
||||||
|
<trim prefix="productId = case" suffix="end,">
|
||||||
|
<foreach collection="list" index="index" item="item">
|
||||||
|
when id = #{item.id,jdbcType=INTEGER} then #{item.productId,jdbcType=VARCHAR}
|
||||||
|
</foreach>
|
||||||
|
</trim>
|
||||||
|
<trim prefix="code = case" suffix="end,">
|
||||||
|
<foreach collection="list" index="index" item="item">
|
||||||
|
when id = #{item.id,jdbcType=INTEGER} then #{item.code,jdbcType=VARCHAR}
|
||||||
|
</foreach>
|
||||||
|
</trim>
|
||||||
|
<trim prefix="`status` = case" suffix="end,">
|
||||||
|
<foreach collection="list" index="index" item="item">
|
||||||
|
when id = #{item.id,jdbcType=INTEGER} then #{item.status,jdbcType=BOOLEAN}
|
||||||
|
</foreach>
|
||||||
|
</trim>
|
||||||
|
</trim>
|
||||||
|
where id in
|
||||||
|
<foreach close=")" collection="list" item="item" open="(" separator=", ">
|
||||||
|
#{item.id,jdbcType=INTEGER}
|
||||||
</foreach>
|
</foreach>
|
||||||
</trim>
|
</update>
|
||||||
<trim prefix="productId = case" suffix="end,">
|
|
||||||
<foreach collection="list" index="index" item="item">
|
<insert id="batchInsert" keyColumn="id" keyProperty="id" parameterType="map" useGeneratedKeys="true">
|
||||||
when id = #{item.id,jdbcType=INTEGER} then #{item.productid,jdbcType=VARCHAR}
|
insert into inv_count_codes
|
||||||
|
(orderIdFk, productId, code, `status`)
|
||||||
|
values
|
||||||
|
<foreach collection="list" item="item" separator=",">
|
||||||
|
(#{item.orderIdFk,jdbcType=VARCHAR}, #{item.productId,jdbcType=VARCHAR}, #{item.code,jdbcType=VARCHAR},
|
||||||
|
#{item.status,jdbcType=BOOLEAN})
|
||||||
</foreach>
|
</foreach>
|
||||||
</trim>
|
</insert>
|
||||||
<trim prefix="code = case" suffix="end,">
|
|
||||||
<foreach collection="list" index="index" item="item">
|
|
||||||
when id = #{item.id,jdbcType=INTEGER} then #{item.code,jdbcType=VARCHAR}
|
|
||||||
</foreach>
|
|
||||||
</trim>
|
|
||||||
<trim prefix="`status` = case" suffix="end,">
|
|
||||||
<foreach collection="list" index="index" item="item">
|
|
||||||
when id = #{item.id,jdbcType=INTEGER} then #{item.status,jdbcType=BOOLEAN}
|
|
||||||
</foreach>
|
|
||||||
</trim>
|
|
||||||
</trim>
|
|
||||||
where id in
|
|
||||||
<foreach close=")" collection="list" item="item" open="(" separator=", ">
|
|
||||||
#{item.id,jdbcType=INTEGER}
|
|
||||||
</foreach>
|
|
||||||
</update>
|
|
||||||
<insert id="batchInsert" keyColumn="id" keyProperty="id" parameterType="map" useGeneratedKeys="true">
|
|
||||||
<!--@mbg.generated-->
|
|
||||||
insert into inv_count_codes
|
|
||||||
(orderIdFk, productId, code, `status`)
|
|
||||||
values
|
|
||||||
<foreach collection="list" item="item" separator=",">
|
|
||||||
(#{item.orderidfk,jdbcType=VARCHAR}, #{item.productid,jdbcType=VARCHAR}, #{item.code,jdbcType=VARCHAR},
|
|
||||||
#{item.status,jdbcType=BOOLEAN})
|
|
||||||
</foreach>
|
|
||||||
</insert>
|
|
||||||
</mapper>
|
</mapper>
|
@ -1,265 +1,273 @@
|
|||||||
<?xml version="1.0" encoding="UTF-8"?>
|
<?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">
|
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||||
<mapper namespace="com.glxp.sale.admin.dao.inventory.InvCountOrderMapper">
|
<mapper namespace="com.glxp.api.admin.dao.inventory.InvCountOrderDao">
|
||||||
<resultMap id="BaseResultMap" type="com.glxp.sale.admin.entity.inventory.InvCountOrder">
|
<resultMap id="BaseResultMap" type="com.glxp.api.admin.entity.inventory.InvCountOrder">
|
||||||
<!--@mbg.generated-->
|
<id column="id" jdbcType="INTEGER" property="id"/>
|
||||||
<!--@Table inv_count_order-->
|
<result column="orderId" jdbcType="VARCHAR" property="orderId"/>
|
||||||
<id column="id" jdbcType="INTEGER" property="id" />
|
<result column="invStorageCode" jdbcType="VARCHAR" property="invStorageCode"/>
|
||||||
<result column="orderId" jdbcType="VARCHAR" property="orderid" />
|
<result column="invWarehouseCode" jdbcType="VARCHAR" property="invWarehouseCode"/>
|
||||||
<result column="invStorageCode" jdbcType="VARCHAR" property="invstoragecode" />
|
<result column="invSpaceCode" jdbcType="VARCHAR" property="invSpaceCode"/>
|
||||||
<result column="invWarehouseCode" jdbcType="VARCHAR" property="invwarehousecode" />
|
<result column="createUser" jdbcType="VARCHAR" property="createUser"/>
|
||||||
<result column="invSpaceCode" jdbcType="VARCHAR" property="invspacecode" />
|
<result column="createTime" jdbcType="TIMESTAMP" property="createTime"/>
|
||||||
<result column="createUser" jdbcType="VARCHAR" property="createuser" />
|
<result column="updateTime" jdbcType="TIMESTAMP" property="updateTime"/>
|
||||||
<result column="createTime" jdbcType="TIMESTAMP" property="createtime" />
|
<result column="auditUser" jdbcType="VARCHAR" property="auditUser"/>
|
||||||
<result column="updateTime" jdbcType="TIMESTAMP" property="updatetime" />
|
<result column="auditTime" jdbcType="TIMESTAMP" property="auditTime"/>
|
||||||
<result column="auditUser" jdbcType="VARCHAR" property="audituser" />
|
<result column="status" jdbcType="BOOLEAN" property="status"/>
|
||||||
<result column="auditTime" jdbcType="TIMESTAMP" property="audittime" />
|
<result column="remark" jdbcType="VARCHAR" property="remark"/>
|
||||||
<result column="status" jdbcType="BOOLEAN" property="status" />
|
</resultMap>
|
||||||
<result column="remark" jdbcType="VARCHAR" property="remark" />
|
|
||||||
</resultMap>
|
<sql id="Base_Column_List">
|
||||||
<sql id="Base_Column_List">
|
|
||||||
<!--@mbg.generated-->
|
|
||||||
id, orderId, invStorageCode, invWarehouseCode, invSpaceCode, `createUser`, createTime,
|
|
||||||
updateTime, auditUser, auditTime, `status`, remark
|
|
||||||
</sql>
|
|
||||||
<select id="selectByPrimaryKey" parameterType="java.lang.Integer" resultMap="BaseResultMap">
|
|
||||||
<!--@mbg.generated-->
|
|
||||||
select
|
|
||||||
<include refid="Base_Column_List" />
|
|
||||||
from inv_count_order
|
|
||||||
where id = #{id,jdbcType=INTEGER}
|
|
||||||
</select>
|
|
||||||
<delete id="deleteByPrimaryKey" parameterType="java.lang.Integer">
|
|
||||||
<!--@mbg.generated-->
|
|
||||||
delete from inv_count_order
|
|
||||||
where id = #{id,jdbcType=INTEGER}
|
|
||||||
</delete>
|
|
||||||
<insert id="insert" parameterType="com.glxp.sale.admin.entity.inventory.InvCountOrder">
|
|
||||||
<!--@mbg.generated-->
|
|
||||||
insert into inv_count_order (id, orderId, invStorageCode,
|
|
||||||
invWarehouseCode, invSpaceCode, `createUser`,
|
|
||||||
createTime, updateTime, auditUser,
|
|
||||||
auditTime, `status`, remark
|
|
||||||
)
|
|
||||||
values (#{id,jdbcType=INTEGER}, #{orderid,jdbcType=VARCHAR}, #{invstoragecode,jdbcType=VARCHAR},
|
|
||||||
#{invwarehousecode,jdbcType=VARCHAR}, #{invspacecode,jdbcType=VARCHAR}, #{createuser,jdbcType=VARCHAR},
|
|
||||||
#{createtime,jdbcType=TIMESTAMP}, #{updatetime,jdbcType=TIMESTAMP}, #{audituser,jdbcType=VARCHAR},
|
|
||||||
#{audittime,jdbcType=TIMESTAMP}, #{status,jdbcType=BOOLEAN}, #{remark,jdbcType=VARCHAR}
|
|
||||||
)
|
|
||||||
</insert>
|
|
||||||
<insert id="insertSelective" parameterType="com.glxp.sale.admin.entity.inventory.InvCountOrder">
|
|
||||||
<!--@mbg.generated-->
|
|
||||||
insert into inv_count_order
|
|
||||||
<trim prefix="(" suffix=")" suffixOverrides=",">
|
|
||||||
<if test="id != null">
|
|
||||||
id,
|
id,
|
||||||
</if>
|
|
||||||
<if test="orderid != null">
|
|
||||||
orderId,
|
orderId,
|
||||||
</if>
|
|
||||||
<if test="invstoragecode != null">
|
|
||||||
invStorageCode,
|
invStorageCode,
|
||||||
</if>
|
|
||||||
<if test="invwarehousecode != null">
|
|
||||||
invWarehouseCode,
|
invWarehouseCode,
|
||||||
</if>
|
|
||||||
<if test="invspacecode != null">
|
|
||||||
invSpaceCode,
|
invSpaceCode,
|
||||||
</if>
|
|
||||||
<if test="createuser != null">
|
|
||||||
`createUser`,
|
`createUser`,
|
||||||
</if>
|
|
||||||
<if test="createtime != null">
|
|
||||||
createTime,
|
createTime,
|
||||||
</if>
|
|
||||||
<if test="updatetime != null">
|
|
||||||
updateTime,
|
updateTime,
|
||||||
</if>
|
|
||||||
<if test="audituser != null">
|
|
||||||
auditUser,
|
auditUser,
|
||||||
</if>
|
|
||||||
<if test="audittime != null">
|
|
||||||
auditTime,
|
auditTime,
|
||||||
</if>
|
|
||||||
<if test="status != null">
|
|
||||||
`status`,
|
`status`,
|
||||||
</if>
|
remark
|
||||||
<if test="remark != null">
|
</sql>
|
||||||
remark,
|
|
||||||
</if>
|
<select id="selectByPrimaryKey" parameterType="java.lang.Integer" resultMap="BaseResultMap">
|
||||||
</trim>
|
select
|
||||||
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
<include refid="Base_Column_List"/>
|
||||||
<if test="id != null">
|
from inv_count_order
|
||||||
#{id,jdbcType=INTEGER},
|
where id = #{id,jdbcType=INTEGER}
|
||||||
</if>
|
</select>
|
||||||
<if test="orderid != null">
|
|
||||||
#{orderid,jdbcType=VARCHAR},
|
<delete id="deleteByPrimaryKey" parameterType="java.lang.Integer">
|
||||||
</if>
|
delete
|
||||||
<if test="invstoragecode != null">
|
from inv_count_order
|
||||||
#{invstoragecode,jdbcType=VARCHAR},
|
where id = #{id,jdbcType=INTEGER}
|
||||||
</if>
|
</delete>
|
||||||
<if test="invwarehousecode != null">
|
|
||||||
#{invwarehousecode,jdbcType=VARCHAR},
|
<insert id="insert" parameterType="com.glxp.api.admin.entity.inventory.InvCountOrder">
|
||||||
</if>
|
insert into inv_count_order (id, orderId, invStorageCode,
|
||||||
<if test="invspacecode != null">
|
invWarehouseCode, invSpaceCode, `createUser`,
|
||||||
#{invspacecode,jdbcType=VARCHAR},
|
createTime, updateTime, auditUser,
|
||||||
</if>
|
auditTime, `status`, remark)
|
||||||
<if test="createuser != null">
|
values (#{id,jdbcType=INTEGER}, #{orderId,jdbcType=VARCHAR}, #{invStorageCode,jdbcType=VARCHAR},
|
||||||
#{createuser,jdbcType=VARCHAR},
|
#{invWarehouseCode,jdbcType=VARCHAR}, #{invSpaceCode,jdbcType=VARCHAR}, #{createUser,jdbcType=VARCHAR},
|
||||||
</if>
|
#{createTime,jdbcType=TIMESTAMP}, #{updateTime,jdbcType=TIMESTAMP}, #{auditUser,jdbcType=VARCHAR},
|
||||||
<if test="createtime != null">
|
#{auditTime,jdbcType=TIMESTAMP}, #{status,jdbcType=BOOLEAN}, #{remark,jdbcType=VARCHAR})
|
||||||
#{createtime,jdbcType=TIMESTAMP},
|
</insert>
|
||||||
</if>
|
<insert id="insertSelective" parameterType="com.glxp.api.admin.entity.inventory.InvCountOrder">
|
||||||
<if test="updatetime != null">
|
<!--@mbg.generated-->
|
||||||
#{updatetime,jdbcType=TIMESTAMP},
|
insert into inv_count_order
|
||||||
</if>
|
<trim prefix="(" suffix=")" suffixOverrides=",">
|
||||||
<if test="audituser != null">
|
<if test="id != null">
|
||||||
#{audituser,jdbcType=VARCHAR},
|
id,
|
||||||
</if>
|
</if>
|
||||||
<if test="audittime != null">
|
<if test="orderId != null">
|
||||||
#{audittime,jdbcType=TIMESTAMP},
|
orderId,
|
||||||
</if>
|
</if>
|
||||||
<if test="status != null">
|
<if test="invStorageCode != null">
|
||||||
#{status,jdbcType=BOOLEAN},
|
invStorageCode,
|
||||||
</if>
|
</if>
|
||||||
<if test="remark != null">
|
<if test="invWarehouseCode != null">
|
||||||
#{remark,jdbcType=VARCHAR},
|
invWarehouseCode,
|
||||||
</if>
|
</if>
|
||||||
</trim>
|
<if test="invSpaceCode != null">
|
||||||
</insert>
|
invSpaceCode,
|
||||||
<update id="updateByPrimaryKeySelective" parameterType="com.glxp.sale.admin.entity.inventory.InvCountOrder">
|
</if>
|
||||||
<!--@mbg.generated-->
|
<if test="createUser != null">
|
||||||
update inv_count_order
|
`createUser`,
|
||||||
<set>
|
</if>
|
||||||
<if test="orderid != null">
|
<if test="createTime != null">
|
||||||
orderId = #{orderid,jdbcType=VARCHAR},
|
createTime,
|
||||||
</if>
|
</if>
|
||||||
<if test="invstoragecode != null">
|
<if test="updateTime != null">
|
||||||
invStorageCode = #{invstoragecode,jdbcType=VARCHAR},
|
updateTime,
|
||||||
</if>
|
</if>
|
||||||
<if test="invwarehousecode != null">
|
<if test="auditUser != null">
|
||||||
invWarehouseCode = #{invwarehousecode,jdbcType=VARCHAR},
|
auditUser,
|
||||||
</if>
|
</if>
|
||||||
<if test="invspacecode != null">
|
<if test="auditTime != null">
|
||||||
invSpaceCode = #{invspacecode,jdbcType=VARCHAR},
|
auditTime,
|
||||||
</if>
|
</if>
|
||||||
<if test="createuser != null">
|
<if test="status != null">
|
||||||
`createUser` = #{createuser,jdbcType=VARCHAR},
|
`status`,
|
||||||
</if>
|
</if>
|
||||||
<if test="createtime != null">
|
<if test="remark != null">
|
||||||
createTime = #{createtime,jdbcType=TIMESTAMP},
|
remark,
|
||||||
</if>
|
</if>
|
||||||
<if test="updatetime != null">
|
</trim>
|
||||||
updateTime = #{updatetime,jdbcType=TIMESTAMP},
|
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
||||||
</if>
|
<if test="id != null">
|
||||||
<if test="audituser != null">
|
#{id,jdbcType=INTEGER},
|
||||||
auditUser = #{audituser,jdbcType=VARCHAR},
|
</if>
|
||||||
</if>
|
<if test="orderId != null">
|
||||||
<if test="audittime != null">
|
#{orderId,jdbcType=VARCHAR},
|
||||||
auditTime = #{audittime,jdbcType=TIMESTAMP},
|
</if>
|
||||||
</if>
|
<if test="invStorageCode != null">
|
||||||
<if test="status != null">
|
#{invStorageCode,jdbcType=VARCHAR},
|
||||||
`status` = #{status,jdbcType=BOOLEAN},
|
</if>
|
||||||
</if>
|
<if test="invWarehouseCode != null">
|
||||||
<if test="remark != null">
|
#{invWarehouseCode,jdbcType=VARCHAR},
|
||||||
remark = #{remark,jdbcType=VARCHAR},
|
</if>
|
||||||
</if>
|
<if test="invSpaceCode != null">
|
||||||
</set>
|
#{invSpaceCode,jdbcType=VARCHAR},
|
||||||
where id = #{id,jdbcType=INTEGER}
|
</if>
|
||||||
</update>
|
<if test="createUser != null">
|
||||||
<update id="updateByPrimaryKey" parameterType="com.glxp.sale.admin.entity.inventory.InvCountOrder">
|
#{createUser,jdbcType=VARCHAR},
|
||||||
<!--@mbg.generated-->
|
</if>
|
||||||
update inv_count_order
|
<if test="createTime != null">
|
||||||
set orderId = #{orderid,jdbcType=VARCHAR},
|
#{createTime,jdbcType=TIMESTAMP},
|
||||||
invStorageCode = #{invstoragecode,jdbcType=VARCHAR},
|
</if>
|
||||||
invWarehouseCode = #{invwarehousecode,jdbcType=VARCHAR},
|
<if test="updateTime != null">
|
||||||
invSpaceCode = #{invspacecode,jdbcType=VARCHAR},
|
#{updateTime,jdbcType=TIMESTAMP},
|
||||||
`createUser` = #{createuser,jdbcType=VARCHAR},
|
</if>
|
||||||
createTime = #{createtime,jdbcType=TIMESTAMP},
|
<if test="auditUser != null">
|
||||||
updateTime = #{updatetime,jdbcType=TIMESTAMP},
|
#{auditUser,jdbcType=VARCHAR},
|
||||||
auditUser = #{audituser,jdbcType=VARCHAR},
|
</if>
|
||||||
auditTime = #{audittime,jdbcType=TIMESTAMP},
|
<if test="auditTime != null">
|
||||||
`status` = #{status,jdbcType=BOOLEAN},
|
#{auditTime,jdbcType=TIMESTAMP},
|
||||||
remark = #{remark,jdbcType=VARCHAR}
|
</if>
|
||||||
where id = #{id,jdbcType=INTEGER}
|
<if test="status != null">
|
||||||
</update>
|
#{status,jdbcType=BOOLEAN},
|
||||||
<update id="updateBatch" parameterType="java.util.List">
|
</if>
|
||||||
<!--@mbg.generated-->
|
<if test="remark != null">
|
||||||
update inv_count_order
|
#{remark,jdbcType=VARCHAR},
|
||||||
<trim prefix="set" suffixOverrides=",">
|
</if>
|
||||||
<trim prefix="orderId = case" suffix="end,">
|
</trim>
|
||||||
<foreach collection="list" index="index" item="item">
|
</insert>
|
||||||
when id = #{item.id,jdbcType=INTEGER} then #{item.orderid,jdbcType=VARCHAR}
|
|
||||||
|
<update id="updateByPrimaryKeySelective" parameterType="com.glxp.api.admin.entity.inventory.InvCountOrder">
|
||||||
|
update inv_count_order
|
||||||
|
<set>
|
||||||
|
<if test="orderId != null">
|
||||||
|
orderId = #{orderId,jdbcType=VARCHAR},
|
||||||
|
</if>
|
||||||
|
<if test="invStorageCode != null">
|
||||||
|
invStorageCode = #{invStorageCode,jdbcType=VARCHAR},
|
||||||
|
</if>
|
||||||
|
<if test="invWarehouseCode != null">
|
||||||
|
invWarehouseCode = #{invWarehouseCode,jdbcType=VARCHAR},
|
||||||
|
</if>
|
||||||
|
<if test="invSpaceCode != null">
|
||||||
|
invSpaceCode = #{invSpaceCode,jdbcType=VARCHAR},
|
||||||
|
</if>
|
||||||
|
<if test="createUser != null">
|
||||||
|
`createUser` = #{createUser,jdbcType=VARCHAR},
|
||||||
|
</if>
|
||||||
|
<if test="createTime != null">
|
||||||
|
createTime = #{createTime,jdbcType=TIMESTAMP},
|
||||||
|
</if>
|
||||||
|
<if test="updateTime != null">
|
||||||
|
updateTime = #{updateTime,jdbcType=TIMESTAMP},
|
||||||
|
</if>
|
||||||
|
<if test="auditUser != null">
|
||||||
|
auditUser = #{auditUser,jdbcType=VARCHAR},
|
||||||
|
</if>
|
||||||
|
<if test="auditTime != null">
|
||||||
|
auditTime = #{auditTime,jdbcType=TIMESTAMP},
|
||||||
|
</if>
|
||||||
|
<if test="status != null">
|
||||||
|
`status` = #{status,jdbcType=BOOLEAN},
|
||||||
|
</if>
|
||||||
|
<if test="remark != null">
|
||||||
|
remark = #{remark,jdbcType=VARCHAR},
|
||||||
|
</if>
|
||||||
|
</set>
|
||||||
|
where id = #{id,jdbcType=INTEGER}
|
||||||
|
</update>
|
||||||
|
|
||||||
|
<update id="updateByPrimaryKey" parameterType="com.glxp.api.admin.entity.inventory.InvCountOrder">
|
||||||
|
update inv_count_order
|
||||||
|
set orderId = #{orderId,jdbcType=VARCHAR},
|
||||||
|
invStorageCode = #{invStorageCode,jdbcType=VARCHAR},
|
||||||
|
invWarehouseCode = #{invWarehouseCode,jdbcType=VARCHAR},
|
||||||
|
invSpaceCode = #{invSpaceCode,jdbcType=VARCHAR},
|
||||||
|
`createUser` = #{createUser,jdbcType=VARCHAR},
|
||||||
|
createTime = #{createTime,jdbcType=TIMESTAMP},
|
||||||
|
updateTime = #{updateTime,jdbcType=TIMESTAMP},
|
||||||
|
auditUser = #{auditUser,jdbcType=VARCHAR},
|
||||||
|
auditTime = #{auditTime,jdbcType=TIMESTAMP},
|
||||||
|
`status` = #{status,jdbcType=BOOLEAN},
|
||||||
|
remark = #{remark,jdbcType=VARCHAR}
|
||||||
|
where id = #{id,jdbcType=INTEGER}
|
||||||
|
</update>
|
||||||
|
|
||||||
|
<update id="updateBatch" parameterType="java.util.List">
|
||||||
|
update inv_count_order
|
||||||
|
<trim prefix="set" suffixOverrides=",">
|
||||||
|
<trim prefix="orderId = case" suffix="end,">
|
||||||
|
<foreach collection="list" index="index" item="item">
|
||||||
|
when id = #{item.id,jdbcType=INTEGER} then #{item.orderId,jdbcType=VARCHAR}
|
||||||
|
</foreach>
|
||||||
|
</trim>
|
||||||
|
<trim prefix="invStorageCode = case" suffix="end,">
|
||||||
|
<foreach collection="list" index="index" item="item">
|
||||||
|
when id = #{item.id,jdbcType=INTEGER} then #{item.invStorageCode,jdbcType=VARCHAR}
|
||||||
|
</foreach>
|
||||||
|
</trim>
|
||||||
|
<trim prefix="invWarehouseCode = case" suffix="end,">
|
||||||
|
<foreach collection="list" index="index" item="item">
|
||||||
|
when id = #{item.id,jdbcType=INTEGER} then #{item.invWarehouseCode,jdbcType=VARCHAR}
|
||||||
|
</foreach>
|
||||||
|
</trim>
|
||||||
|
<trim prefix="invSpaceCode = case" suffix="end,">
|
||||||
|
<foreach collection="list" index="index" item="item">
|
||||||
|
when id = #{item.id,jdbcType=INTEGER} then #{item.invSpaceCode,jdbcType=VARCHAR}
|
||||||
|
</foreach>
|
||||||
|
</trim>
|
||||||
|
<trim prefix="`createUser` = case" suffix="end,">
|
||||||
|
<foreach collection="list" index="index" item="item">
|
||||||
|
when id = #{item.id,jdbcType=INTEGER} then #{item.createUser,jdbcType=VARCHAR}
|
||||||
|
</foreach>
|
||||||
|
</trim>
|
||||||
|
<trim prefix="createTime = case" suffix="end,">
|
||||||
|
<foreach collection="list" index="index" item="item">
|
||||||
|
when id = #{item.id,jdbcType=INTEGER} then #{item.createTime,jdbcType=TIMESTAMP}
|
||||||
|
</foreach>
|
||||||
|
</trim>
|
||||||
|
<trim prefix="updateTime = case" suffix="end,">
|
||||||
|
<foreach collection="list" index="index" item="item">
|
||||||
|
when id = #{item.id,jdbcType=INTEGER} then #{item.updateTime,jdbcType=TIMESTAMP}
|
||||||
|
</foreach>
|
||||||
|
</trim>
|
||||||
|
<trim prefix="auditUser = case" suffix="end,">
|
||||||
|
<foreach collection="list" index="index" item="item">
|
||||||
|
when id = #{item.id,jdbcType=INTEGER} then #{item.auditUser,jdbcType=VARCHAR}
|
||||||
|
</foreach>
|
||||||
|
</trim>
|
||||||
|
<trim prefix="auditTime = case" suffix="end,">
|
||||||
|
<foreach collection="list" index="index" item="item">
|
||||||
|
when id = #{item.id,jdbcType=INTEGER} then #{item.auditTime,jdbcType=TIMESTAMP}
|
||||||
|
</foreach>
|
||||||
|
</trim>
|
||||||
|
<trim prefix="`status` = case" suffix="end,">
|
||||||
|
<foreach collection="list" index="index" item="item">
|
||||||
|
when id = #{item.id,jdbcType=INTEGER} then #{item.status,jdbcType=BOOLEAN}
|
||||||
|
</foreach>
|
||||||
|
</trim>
|
||||||
|
<trim prefix="remark = case" suffix="end,">
|
||||||
|
<foreach collection="list" index="index" item="item">
|
||||||
|
when id = #{item.id,jdbcType=INTEGER} then #{item.remark,jdbcType=VARCHAR}
|
||||||
|
</foreach>
|
||||||
|
</trim>
|
||||||
|
</trim>
|
||||||
|
where id in
|
||||||
|
<foreach close=")" collection="list" item="item" open="(" separator=", ">
|
||||||
|
#{item.id,jdbcType=INTEGER}
|
||||||
</foreach>
|
</foreach>
|
||||||
</trim>
|
</update>
|
||||||
<trim prefix="invStorageCode = case" suffix="end,">
|
|
||||||
<foreach collection="list" index="index" item="item">
|
<insert id="batchInsert" parameterType="map">
|
||||||
when id = #{item.id,jdbcType=INTEGER} then #{item.invstoragecode,jdbcType=VARCHAR}
|
insert into inv_count_order
|
||||||
|
(id, orderId, invStorageCode, invWarehouseCode, invSpaceCode, `createUser`, createTime,
|
||||||
|
updateTime, auditUser, auditTime, `status`, remark)
|
||||||
|
values
|
||||||
|
<foreach collection="list" item="item" separator=",">
|
||||||
|
(#{item.id,jdbcType=INTEGER}, #{item.orderid,jdbcType=VARCHAR}, #{item.invstoragecode,jdbcType=VARCHAR},
|
||||||
|
#{item.invwarehousecode,jdbcType=VARCHAR}, #{item.invspacecode,jdbcType=VARCHAR},
|
||||||
|
#{item.createuser,jdbcType=VARCHAR}, #{item.createtime,jdbcType=TIMESTAMP},
|
||||||
|
#{item.updatetime,jdbcType=TIMESTAMP},
|
||||||
|
#{item.audituser,jdbcType=VARCHAR}, #{item.audittime,jdbcType=TIMESTAMP}, #{item.status,jdbcType=BOOLEAN},
|
||||||
|
#{item.remark,jdbcType=VARCHAR})
|
||||||
</foreach>
|
</foreach>
|
||||||
</trim>
|
</insert>
|
||||||
<trim prefix="invWarehouseCode = case" suffix="end,">
|
|
||||||
<foreach collection="list" index="index" item="item">
|
|
||||||
when id = #{item.id,jdbcType=INTEGER} then #{item.invwarehousecode,jdbcType=VARCHAR}
|
|
||||||
</foreach>
|
|
||||||
</trim>
|
|
||||||
<trim prefix="invSpaceCode = case" suffix="end,">
|
|
||||||
<foreach collection="list" index="index" item="item">
|
|
||||||
when id = #{item.id,jdbcType=INTEGER} then #{item.invspacecode,jdbcType=VARCHAR}
|
|
||||||
</foreach>
|
|
||||||
</trim>
|
|
||||||
<trim prefix="`createUser` = case" suffix="end,">
|
|
||||||
<foreach collection="list" index="index" item="item">
|
|
||||||
when id = #{item.id,jdbcType=INTEGER} then #{item.createuser,jdbcType=VARCHAR}
|
|
||||||
</foreach>
|
|
||||||
</trim>
|
|
||||||
<trim prefix="createTime = case" suffix="end,">
|
|
||||||
<foreach collection="list" index="index" item="item">
|
|
||||||
when id = #{item.id,jdbcType=INTEGER} then #{item.createtime,jdbcType=TIMESTAMP}
|
|
||||||
</foreach>
|
|
||||||
</trim>
|
|
||||||
<trim prefix="updateTime = case" suffix="end,">
|
|
||||||
<foreach collection="list" index="index" item="item">
|
|
||||||
when id = #{item.id,jdbcType=INTEGER} then #{item.updatetime,jdbcType=TIMESTAMP}
|
|
||||||
</foreach>
|
|
||||||
</trim>
|
|
||||||
<trim prefix="auditUser = case" suffix="end,">
|
|
||||||
<foreach collection="list" index="index" item="item">
|
|
||||||
when id = #{item.id,jdbcType=INTEGER} then #{item.audituser,jdbcType=VARCHAR}
|
|
||||||
</foreach>
|
|
||||||
</trim>
|
|
||||||
<trim prefix="auditTime = case" suffix="end,">
|
|
||||||
<foreach collection="list" index="index" item="item">
|
|
||||||
when id = #{item.id,jdbcType=INTEGER} then #{item.audittime,jdbcType=TIMESTAMP}
|
|
||||||
</foreach>
|
|
||||||
</trim>
|
|
||||||
<trim prefix="`status` = case" suffix="end,">
|
|
||||||
<foreach collection="list" index="index" item="item">
|
|
||||||
when id = #{item.id,jdbcType=INTEGER} then #{item.status,jdbcType=BOOLEAN}
|
|
||||||
</foreach>
|
|
||||||
</trim>
|
|
||||||
<trim prefix="remark = case" suffix="end,">
|
|
||||||
<foreach collection="list" index="index" item="item">
|
|
||||||
when id = #{item.id,jdbcType=INTEGER} then #{item.remark,jdbcType=VARCHAR}
|
|
||||||
</foreach>
|
|
||||||
</trim>
|
|
||||||
</trim>
|
|
||||||
where id in
|
|
||||||
<foreach close=")" collection="list" item="item" open="(" separator=", ">
|
|
||||||
#{item.id,jdbcType=INTEGER}
|
|
||||||
</foreach>
|
|
||||||
</update>
|
|
||||||
<insert id="batchInsert" parameterType="map">
|
|
||||||
<!--@mbg.generated-->
|
|
||||||
insert into inv_count_order
|
|
||||||
(id, orderId, invStorageCode, invWarehouseCode, invSpaceCode, `createUser`, createTime,
|
|
||||||
updateTime, auditUser, auditTime, `status`, remark)
|
|
||||||
values
|
|
||||||
<foreach collection="list" item="item" separator=",">
|
|
||||||
(#{item.id,jdbcType=INTEGER}, #{item.orderid,jdbcType=VARCHAR}, #{item.invstoragecode,jdbcType=VARCHAR},
|
|
||||||
#{item.invwarehousecode,jdbcType=VARCHAR}, #{item.invspacecode,jdbcType=VARCHAR},
|
|
||||||
#{item.createuser,jdbcType=VARCHAR}, #{item.createtime,jdbcType=TIMESTAMP}, #{item.updatetime,jdbcType=TIMESTAMP},
|
|
||||||
#{item.audituser,jdbcType=VARCHAR}, #{item.audittime,jdbcType=TIMESTAMP}, #{item.status,jdbcType=BOOLEAN},
|
|
||||||
#{item.remark,jdbcType=VARCHAR})
|
|
||||||
</foreach>
|
|
||||||
</insert>
|
|
||||||
</mapper>
|
</mapper>
|
@ -1,257 +1,267 @@
|
|||||||
<?xml version="1.0" encoding="UTF-8"?>
|
<?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">
|
<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
||||||
<mapper namespace="com.glxp.sale.admin.dao.inventory.InvCountOrderDetailMapper">
|
<mapper namespace="com.glxp.api.admin.dao.inventory.InvCountOrderDetailDao">
|
||||||
<resultMap id="BaseResultMap" type="com.glxp.sale.admin.entity.inventory.InvCountOrderDetail">
|
<resultMap id="BaseResultMap" type="com.glxp.api.admin.entity.inventory.InvCountOrderDetail">
|
||||||
<!--@mbg.generated-->
|
<id column="id" jdbcType="INTEGER" property="id"/>
|
||||||
<!--@Table inv_count_order_detail-->
|
<result column="orderIdFk" jdbcType="VARCHAR" property="orderIdFk"/>
|
||||||
<id column="id" jdbcType="INTEGER" property="id" />
|
<result column="productId" jdbcType="VARCHAR" property="productId"/>
|
||||||
<result column="orderIdFk" jdbcType="VARCHAR" property="orderidfk" />
|
<result column="batchNo" jdbcType="VARCHAR" property="batchNo"/>
|
||||||
<result column="productId" jdbcType="VARCHAR" property="productid" />
|
<result column="produceDate" jdbcType="TIMESTAMP" property="produceDate"/>
|
||||||
<result column="batchNo" jdbcType="VARCHAR" property="batchno" />
|
<result column="expireDate" jdbcType="TIMESTAMP" property="expireDate"/>
|
||||||
<result column="produceDate" jdbcType="TIMESTAMP" property="producedate" />
|
<result column="serialNo" jdbcType="VARCHAR" property="serialNo"/>
|
||||||
<result column="expireDate" jdbcType="TIMESTAMP" property="expiredate" />
|
<result column="countNum" jdbcType="INTEGER" property="countNum"/>
|
||||||
<result column="serialNo" jdbcType="VARCHAR" property="serialno" />
|
<result column="bookNum" jdbcType="INTEGER" property="bookNum"/>
|
||||||
<result column="countNum" jdbcType="INTEGER" property="countnum" />
|
<result column="profitNum" jdbcType="INTEGER" property="profitNum"/>
|
||||||
<result column="bookNum" jdbcType="INTEGER" property="booknum" />
|
<result column="lossNum" jdbcType="INTEGER" property="lossNum"/>
|
||||||
<result column="profitNum" jdbcType="INTEGER" property="profitnum" />
|
<result column="status" jdbcType="BOOLEAN" property="status"/>
|
||||||
<result column="lossNum" jdbcType="INTEGER" property="lossnum" />
|
</resultMap>
|
||||||
<result column="status" jdbcType="BOOLEAN" property="status" />
|
|
||||||
</resultMap>
|
<sql id="Base_Column_List">
|
||||||
<sql id="Base_Column_List">
|
id,
|
||||||
<!--@mbg.generated-->
|
|
||||||
id, orderIdFk, productId, batchNo, produceDate, expireDate, serialNo, countNum, bookNum,
|
|
||||||
profitNum, lossNum, `status`
|
|
||||||
</sql>
|
|
||||||
<select id="selectByPrimaryKey" parameterType="java.lang.Integer" resultMap="BaseResultMap">
|
|
||||||
<!--@mbg.generated-->
|
|
||||||
select
|
|
||||||
<include refid="Base_Column_List" />
|
|
||||||
from inv_count_order_detail
|
|
||||||
where id = #{id,jdbcType=INTEGER}
|
|
||||||
</select>
|
|
||||||
<delete id="deleteByPrimaryKey" parameterType="java.lang.Integer">
|
|
||||||
<!--@mbg.generated-->
|
|
||||||
delete from inv_count_order_detail
|
|
||||||
where id = #{id,jdbcType=INTEGER}
|
|
||||||
</delete>
|
|
||||||
<insert id="insert" keyColumn="id" keyProperty="id" parameterType="com.glxp.sale.admin.entity.inventory.InvCountOrderDetail" useGeneratedKeys="true">
|
|
||||||
<!--@mbg.generated-->
|
|
||||||
insert into inv_count_order_detail (orderIdFk, productId, batchNo,
|
|
||||||
produceDate, expireDate, serialNo,
|
|
||||||
countNum, bookNum, profitNum,
|
|
||||||
lossNum, `status`)
|
|
||||||
values (#{orderidfk,jdbcType=VARCHAR}, #{productid,jdbcType=VARCHAR}, #{batchno,jdbcType=VARCHAR},
|
|
||||||
#{producedate,jdbcType=TIMESTAMP}, #{expiredate,jdbcType=TIMESTAMP}, #{serialno,jdbcType=VARCHAR},
|
|
||||||
#{countnum,jdbcType=INTEGER}, #{booknum,jdbcType=INTEGER}, #{profitnum,jdbcType=INTEGER},
|
|
||||||
#{lossnum,jdbcType=INTEGER}, #{status,jdbcType=BOOLEAN})
|
|
||||||
</insert>
|
|
||||||
<insert id="insertSelective" keyColumn="id" keyProperty="id" parameterType="com.glxp.sale.admin.entity.inventory.InvCountOrderDetail" useGeneratedKeys="true">
|
|
||||||
<!--@mbg.generated-->
|
|
||||||
insert into inv_count_order_detail
|
|
||||||
<trim prefix="(" suffix=")" suffixOverrides=",">
|
|
||||||
<if test="orderidfk != null">
|
|
||||||
orderIdFk,
|
orderIdFk,
|
||||||
</if>
|
|
||||||
<if test="productid != null">
|
|
||||||
productId,
|
productId,
|
||||||
</if>
|
|
||||||
<if test="batchno != null">
|
|
||||||
batchNo,
|
batchNo,
|
||||||
</if>
|
|
||||||
<if test="producedate != null">
|
|
||||||
produceDate,
|
produceDate,
|
||||||
</if>
|
|
||||||
<if test="expiredate != null">
|
|
||||||
expireDate,
|
expireDate,
|
||||||
</if>
|
|
||||||
<if test="serialno != null">
|
|
||||||
serialNo,
|
serialNo,
|
||||||
</if>
|
|
||||||
<if test="countnum != null">
|
|
||||||
countNum,
|
countNum,
|
||||||
</if>
|
|
||||||
<if test="booknum != null">
|
|
||||||
bookNum,
|
bookNum,
|
||||||
</if>
|
|
||||||
<if test="profitnum != null">
|
|
||||||
profitNum,
|
profitNum,
|
||||||
</if>
|
|
||||||
<if test="lossnum != null">
|
|
||||||
lossNum,
|
lossNum,
|
||||||
</if>
|
`status`
|
||||||
<if test="status != null">
|
</sql>
|
||||||
`status`,
|
|
||||||
</if>
|
<select id="selectByPrimaryKey" parameterType="java.lang.Integer" resultMap="BaseResultMap">
|
||||||
</trim>
|
select
|
||||||
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
<include refid="Base_Column_List"/>
|
||||||
<if test="orderidfk != null">
|
from inv_count_order_detail
|
||||||
#{orderidfk,jdbcType=VARCHAR},
|
where id = #{id,jdbcType=INTEGER}
|
||||||
</if>
|
</select>
|
||||||
<if test="productid != null">
|
|
||||||
#{productid,jdbcType=VARCHAR},
|
<delete id="deleteByPrimaryKey" parameterType="java.lang.Integer">
|
||||||
</if>
|
delete
|
||||||
<if test="batchno != null">
|
from inv_count_order_detail
|
||||||
#{batchno,jdbcType=VARCHAR},
|
where id = #{id,jdbcType=INTEGER}
|
||||||
</if>
|
</delete>
|
||||||
<if test="producedate != null">
|
|
||||||
#{producedate,jdbcType=TIMESTAMP},
|
<insert id="insert" keyColumn="id" keyProperty="id"
|
||||||
</if>
|
parameterType="com.glxp.api.admin.entity.inventory.InvCountOrderDetail" useGeneratedKeys="true">
|
||||||
<if test="expiredate != null">
|
insert into inv_count_order_detail (orderIdFk, productId, batchNo,
|
||||||
#{expiredate,jdbcType=TIMESTAMP},
|
produceDate, expireDate, serialNo,
|
||||||
</if>
|
countNum, bookNum, profitNum,
|
||||||
<if test="serialno != null">
|
lossNum, `status`)
|
||||||
#{serialno,jdbcType=VARCHAR},
|
values (#{orderIdFk,jdbcType=VARCHAR}, #{productId,jdbcType=VARCHAR}, #{batchNo,jdbcType=VARCHAR},
|
||||||
</if>
|
#{produceDate,jdbcType=TIMESTAMP}, #{expireDate,jdbcType=TIMESTAMP}, #{serialNo,jdbcType=VARCHAR},
|
||||||
<if test="countnum != null">
|
#{countNum,jdbcType=INTEGER}, #{bookNum,jdbcType=INTEGER}, #{profitNum,jdbcType=INTEGER},
|
||||||
#{countnum,jdbcType=INTEGER},
|
#{lossNum,jdbcType=INTEGER}, #{status,jdbcType=BOOLEAN})
|
||||||
</if>
|
</insert>
|
||||||
<if test="booknum != null">
|
|
||||||
#{booknum,jdbcType=INTEGER},
|
<insert id="insertSelective" keyColumn="id" keyProperty="id"
|
||||||
</if>
|
parameterType="com.glxp.api.admin.entity.inventory.InvCountOrderDetail" useGeneratedKeys="true">
|
||||||
<if test="profitnum != null">
|
insert into inv_count_order_detail
|
||||||
#{profitnum,jdbcType=INTEGER},
|
<trim prefix="(" suffix=")" suffixOverrides=",">
|
||||||
</if>
|
<if test="orderIdFk != null">
|
||||||
<if test="lossnum != null">
|
orderIdFk,
|
||||||
#{lossnum,jdbcType=INTEGER},
|
</if>
|
||||||
</if>
|
<if test="productId != null">
|
||||||
<if test="status != null">
|
productId,
|
||||||
#{status,jdbcType=BOOLEAN},
|
</if>
|
||||||
</if>
|
<if test="batchNo != null">
|
||||||
</trim>
|
batchNo,
|
||||||
</insert>
|
</if>
|
||||||
<update id="updateByPrimaryKeySelective" parameterType="com.glxp.sale.admin.entity.inventory.InvCountOrderDetail">
|
<if test="produceDate != null">
|
||||||
<!--@mbg.generated-->
|
produceDate,
|
||||||
update inv_count_order_detail
|
</if>
|
||||||
<set>
|
<if test="expireDate != null">
|
||||||
<if test="orderidfk != null">
|
expireDate,
|
||||||
orderIdFk = #{orderidfk,jdbcType=VARCHAR},
|
</if>
|
||||||
</if>
|
<if test="serialNo != null">
|
||||||
<if test="productid != null">
|
serialNo,
|
||||||
productId = #{productid,jdbcType=VARCHAR},
|
</if>
|
||||||
</if>
|
<if test="countNum != null">
|
||||||
<if test="batchno != null">
|
countNum,
|
||||||
batchNo = #{batchno,jdbcType=VARCHAR},
|
</if>
|
||||||
</if>
|
<if test="bookNum != null">
|
||||||
<if test="producedate != null">
|
bookNum,
|
||||||
produceDate = #{producedate,jdbcType=TIMESTAMP},
|
</if>
|
||||||
</if>
|
<if test="profitNum != null">
|
||||||
<if test="expiredate != null">
|
profitNum,
|
||||||
expireDate = #{expiredate,jdbcType=TIMESTAMP},
|
</if>
|
||||||
</if>
|
<if test="lossNum != null">
|
||||||
<if test="serialno != null">
|
lossNum,
|
||||||
serialNo = #{serialno,jdbcType=VARCHAR},
|
</if>
|
||||||
</if>
|
<if test="status != null">
|
||||||
<if test="countnum != null">
|
`status`,
|
||||||
countNum = #{countnum,jdbcType=INTEGER},
|
</if>
|
||||||
</if>
|
</trim>
|
||||||
<if test="booknum != null">
|
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
||||||
bookNum = #{booknum,jdbcType=INTEGER},
|
<if test="orderIdFk != null">
|
||||||
</if>
|
#{orderIdFk,jdbcType=VARCHAR},
|
||||||
<if test="profitnum != null">
|
</if>
|
||||||
profitNum = #{profitnum,jdbcType=INTEGER},
|
<if test="productId != null">
|
||||||
</if>
|
#{productId,jdbcType=VARCHAR},
|
||||||
<if test="lossnum != null">
|
</if>
|
||||||
lossNum = #{lossnum,jdbcType=INTEGER},
|
<if test="batchNo != null">
|
||||||
</if>
|
#{batchNo,jdbcType=VARCHAR},
|
||||||
<if test="status != null">
|
</if>
|
||||||
`status` = #{status,jdbcType=BOOLEAN},
|
<if test="produceDate != null">
|
||||||
</if>
|
#{produceDate,jdbcType=TIMESTAMP},
|
||||||
</set>
|
</if>
|
||||||
where id = #{id,jdbcType=INTEGER}
|
<if test="expireDate != null">
|
||||||
</update>
|
#{expireDate,jdbcType=TIMESTAMP},
|
||||||
<update id="updateByPrimaryKey" parameterType="com.glxp.sale.admin.entity.inventory.InvCountOrderDetail">
|
</if>
|
||||||
<!--@mbg.generated-->
|
<if test="serialNo != null">
|
||||||
update inv_count_order_detail
|
#{serialNo,jdbcType=VARCHAR},
|
||||||
set orderIdFk = #{orderidfk,jdbcType=VARCHAR},
|
</if>
|
||||||
productId = #{productid,jdbcType=VARCHAR},
|
<if test="countNum != null">
|
||||||
batchNo = #{batchno,jdbcType=VARCHAR},
|
#{countNum,jdbcType=INTEGER},
|
||||||
produceDate = #{producedate,jdbcType=TIMESTAMP},
|
</if>
|
||||||
expireDate = #{expiredate,jdbcType=TIMESTAMP},
|
<if test="bookNum != null">
|
||||||
serialNo = #{serialno,jdbcType=VARCHAR},
|
#{bookNum,jdbcType=INTEGER},
|
||||||
countNum = #{countnum,jdbcType=INTEGER},
|
</if>
|
||||||
bookNum = #{booknum,jdbcType=INTEGER},
|
<if test="profitNum != null">
|
||||||
profitNum = #{profitnum,jdbcType=INTEGER},
|
#{profitNum,jdbcType=INTEGER},
|
||||||
lossNum = #{lossnum,jdbcType=INTEGER},
|
</if>
|
||||||
`status` = #{status,jdbcType=BOOLEAN}
|
<if test="lossNum != null">
|
||||||
where id = #{id,jdbcType=INTEGER}
|
#{lossNum,jdbcType=INTEGER},
|
||||||
</update>
|
</if>
|
||||||
<update id="updateBatch" parameterType="java.util.List">
|
<if test="status != null">
|
||||||
<!--@mbg.generated-->
|
#{status,jdbcType=BOOLEAN},
|
||||||
update inv_count_order_detail
|
</if>
|
||||||
<trim prefix="set" suffixOverrides=",">
|
</trim>
|
||||||
<trim prefix="orderIdFk = case" suffix="end,">
|
</insert>
|
||||||
<foreach collection="list" index="index" item="item">
|
|
||||||
when id = #{item.id,jdbcType=INTEGER} then #{item.orderidfk,jdbcType=VARCHAR}
|
<update id="updateByPrimaryKeySelective" parameterType="com.glxp.api.admin.entity.inventory.InvCountOrderDetail">
|
||||||
|
update inv_count_order_detail
|
||||||
|
<set>
|
||||||
|
<if test="orderIdFk != null">
|
||||||
|
orderIdFk = #{orderIdFk,jdbcType=VARCHAR},
|
||||||
|
</if>
|
||||||
|
<if test="productId != null">
|
||||||
|
productId = #{productId,jdbcType=VARCHAR},
|
||||||
|
</if>
|
||||||
|
<if test="batchNo != null">
|
||||||
|
batchNo = #{batchNo,jdbcType=VARCHAR},
|
||||||
|
</if>
|
||||||
|
<if test="produceDate != null">
|
||||||
|
produceDate = #{produceDate,jdbcType=TIMESTAMP},
|
||||||
|
</if>
|
||||||
|
<if test="expireDate != null">
|
||||||
|
expireDate = #{expireDate,jdbcType=TIMESTAMP},
|
||||||
|
</if>
|
||||||
|
<if test="serialNo != null">
|
||||||
|
serialNo = #{serialNo,jdbcType=VARCHAR},
|
||||||
|
</if>
|
||||||
|
<if test="countNum != null">
|
||||||
|
countNum = #{countNum,jdbcType=INTEGER},
|
||||||
|
</if>
|
||||||
|
<if test="bookNum != null">
|
||||||
|
bookNum = #{bookNum,jdbcType=INTEGER},
|
||||||
|
</if>
|
||||||
|
<if test="profitNum != null">
|
||||||
|
profitNum = #{profitNum,jdbcType=INTEGER},
|
||||||
|
</if>
|
||||||
|
<if test="lossNum != null">
|
||||||
|
lossNum = #{lossNum,jdbcType=INTEGER},
|
||||||
|
</if>
|
||||||
|
<if test="status != null">
|
||||||
|
`status` = #{status,jdbcType=BOOLEAN},
|
||||||
|
</if>
|
||||||
|
</set>
|
||||||
|
where id = #{id,jdbcType=INTEGER}
|
||||||
|
</update>
|
||||||
|
|
||||||
|
<update id="updateByPrimaryKey" parameterType="com.glxp.api.admin.entity.inventory.InvCountOrderDetail">
|
||||||
|
update inv_count_order_detail
|
||||||
|
set orderIdFk = #{orderIdFk,jdbcType=VARCHAR},
|
||||||
|
productId = #{productId,jdbcType=VARCHAR},
|
||||||
|
batchNo = #{batchNo,jdbcType=VARCHAR},
|
||||||
|
produceDate = #{produceDate,jdbcType=TIMESTAMP},
|
||||||
|
expireDate = #{expireDate,jdbcType=TIMESTAMP},
|
||||||
|
serialNo = #{serialNo,jdbcType=VARCHAR},
|
||||||
|
countNum = #{countNum,jdbcType=INTEGER},
|
||||||
|
bookNum = #{bookNum,jdbcType=INTEGER},
|
||||||
|
profitNum = #{productId,jdbcType=INTEGER},
|
||||||
|
lossNum = #{lossNum,jdbcType=INTEGER},
|
||||||
|
`status` = #{status,jdbcType=BOOLEAN}
|
||||||
|
where id = #{id,jdbcType=INTEGER}
|
||||||
|
</update>
|
||||||
|
|
||||||
|
<update id="updateBatch" parameterType="java.util.List">
|
||||||
|
update inv_count_order_detail
|
||||||
|
<trim prefix="set" suffixOverrides=",">
|
||||||
|
<trim prefix="orderIdFk = case" suffix="end,">
|
||||||
|
<foreach collection="list" index="index" item="item">
|
||||||
|
when id = #{item.id,jdbcType=INTEGER} then #{item.orderIdFk,jdbcType=VARCHAR}
|
||||||
|
</foreach>
|
||||||
|
</trim>
|
||||||
|
<trim prefix="productId = case" suffix="end,">
|
||||||
|
<foreach collection="list" index="index" item="item">
|
||||||
|
when id = #{item.id,jdbcType=INTEGER} then #{item.productId,jdbcType=VARCHAR}
|
||||||
|
</foreach>
|
||||||
|
</trim>
|
||||||
|
<trim prefix="batchNo = case" suffix="end,">
|
||||||
|
<foreach collection="list" index="index" item="item">
|
||||||
|
when id = #{item.id,jdbcType=INTEGER} then #{item.batchNo,jdbcType=VARCHAR}
|
||||||
|
</foreach>
|
||||||
|
</trim>
|
||||||
|
<trim prefix="produceDate = case" suffix="end,">
|
||||||
|
<foreach collection="list" index="index" item="item">
|
||||||
|
when id = #{item.id,jdbcType=INTEGER} then #{item.produceDate,jdbcType=TIMESTAMP}
|
||||||
|
</foreach>
|
||||||
|
</trim>
|
||||||
|
<trim prefix="expireDate = case" suffix="end,">
|
||||||
|
<foreach collection="list" index="index" item="item">
|
||||||
|
when id = #{item.id,jdbcType=INTEGER} then #{item.expireDate,jdbcType=TIMESTAMP}
|
||||||
|
</foreach>
|
||||||
|
</trim>
|
||||||
|
<trim prefix="serialNo = case" suffix="end,">
|
||||||
|
<foreach collection="list" index="index" item="item">
|
||||||
|
when id = #{item.id,jdbcType=INTEGER} then #{item.serialNo,jdbcType=VARCHAR}
|
||||||
|
</foreach>
|
||||||
|
</trim>
|
||||||
|
<trim prefix="countNum = case" suffix="end,">
|
||||||
|
<foreach collection="list" index="index" item="item">
|
||||||
|
when id = #{item.id,jdbcType=INTEGER} then #{item.countNum,jdbcType=INTEGER}
|
||||||
|
</foreach>
|
||||||
|
</trim>
|
||||||
|
<trim prefix="bookNum = case" suffix="end,">
|
||||||
|
<foreach collection="list" index="index" item="item">
|
||||||
|
when id = #{item.id,jdbcType=INTEGER} then #{item.bookNum,jdbcType=INTEGER}
|
||||||
|
</foreach>
|
||||||
|
</trim>
|
||||||
|
<trim prefix="profitNum = case" suffix="end,">
|
||||||
|
<foreach collection="list" index="index" item="item">
|
||||||
|
when id = #{item.id,jdbcType=INTEGER} then #{item.profitNum,jdbcType=INTEGER}
|
||||||
|
</foreach>
|
||||||
|
</trim>
|
||||||
|
<trim prefix="lossNum = case" suffix="end,">
|
||||||
|
<foreach collection="list" index="index" item="item">
|
||||||
|
when id = #{item.id,jdbcType=INTEGER} then #{item.lossNum,jdbcType=INTEGER}
|
||||||
|
</foreach>
|
||||||
|
</trim>
|
||||||
|
<trim prefix="`status` = case" suffix="end,">
|
||||||
|
<foreach collection="list" index="index" item="item">
|
||||||
|
when id = #{item.id,jdbcType=INTEGER} then #{item.status,jdbcType=BOOLEAN}
|
||||||
|
</foreach>
|
||||||
|
</trim>
|
||||||
|
</trim>
|
||||||
|
where id in
|
||||||
|
<foreach close=")" collection="list" item="item" open="(" separator=", ">
|
||||||
|
#{item.id,jdbcType=INTEGER}
|
||||||
</foreach>
|
</foreach>
|
||||||
</trim>
|
</update>
|
||||||
<trim prefix="productId = case" suffix="end,">
|
|
||||||
<foreach collection="list" index="index" item="item">
|
<insert id="batchInsert" keyColumn="id" keyProperty="id" parameterType="map" useGeneratedKeys="true">
|
||||||
when id = #{item.id,jdbcType=INTEGER} then #{item.productid,jdbcType=VARCHAR}
|
insert into inv_count_order_detail
|
||||||
|
(orderIdFk, productId, batchNo, produceDate, expireDate, serialNo, countNum, bookNum,
|
||||||
|
profitNum, lossNum, `status`)
|
||||||
|
values
|
||||||
|
<foreach collection="list" item="item" separator=",">
|
||||||
|
(#{item.orderIdFk,jdbcType=VARCHAR}, #{item.productId,jdbcType=VARCHAR}, #{item.batchNo,jdbcType=VARCHAR},
|
||||||
|
#{item.produceDate,jdbcType=TIMESTAMP}, #{item.expireDate,jdbcType=TIMESTAMP},
|
||||||
|
#{item.serialNo,jdbcType=VARCHAR}, #{item.countNum,jdbcType=INTEGER}, #{item.bookNum,jdbcType=INTEGER},
|
||||||
|
#{item.profitNum,jdbcType=INTEGER}, #{item.lossNum,jdbcType=INTEGER}, #{item.status,jdbcType=BOOLEAN})
|
||||||
</foreach>
|
</foreach>
|
||||||
</trim>
|
</insert>
|
||||||
<trim prefix="batchNo = case" suffix="end,">
|
|
||||||
<foreach collection="list" index="index" item="item">
|
|
||||||
when id = #{item.id,jdbcType=INTEGER} then #{item.batchno,jdbcType=VARCHAR}
|
|
||||||
</foreach>
|
|
||||||
</trim>
|
|
||||||
<trim prefix="produceDate = case" suffix="end,">
|
|
||||||
<foreach collection="list" index="index" item="item">
|
|
||||||
when id = #{item.id,jdbcType=INTEGER} then #{item.producedate,jdbcType=TIMESTAMP}
|
|
||||||
</foreach>
|
|
||||||
</trim>
|
|
||||||
<trim prefix="expireDate = case" suffix="end,">
|
|
||||||
<foreach collection="list" index="index" item="item">
|
|
||||||
when id = #{item.id,jdbcType=INTEGER} then #{item.expiredate,jdbcType=TIMESTAMP}
|
|
||||||
</foreach>
|
|
||||||
</trim>
|
|
||||||
<trim prefix="serialNo = case" suffix="end,">
|
|
||||||
<foreach collection="list" index="index" item="item">
|
|
||||||
when id = #{item.id,jdbcType=INTEGER} then #{item.serialno,jdbcType=VARCHAR}
|
|
||||||
</foreach>
|
|
||||||
</trim>
|
|
||||||
<trim prefix="countNum = case" suffix="end,">
|
|
||||||
<foreach collection="list" index="index" item="item">
|
|
||||||
when id = #{item.id,jdbcType=INTEGER} then #{item.countnum,jdbcType=INTEGER}
|
|
||||||
</foreach>
|
|
||||||
</trim>
|
|
||||||
<trim prefix="bookNum = case" suffix="end,">
|
|
||||||
<foreach collection="list" index="index" item="item">
|
|
||||||
when id = #{item.id,jdbcType=INTEGER} then #{item.booknum,jdbcType=INTEGER}
|
|
||||||
</foreach>
|
|
||||||
</trim>
|
|
||||||
<trim prefix="profitNum = case" suffix="end,">
|
|
||||||
<foreach collection="list" index="index" item="item">
|
|
||||||
when id = #{item.id,jdbcType=INTEGER} then #{item.profitnum,jdbcType=INTEGER}
|
|
||||||
</foreach>
|
|
||||||
</trim>
|
|
||||||
<trim prefix="lossNum = case" suffix="end,">
|
|
||||||
<foreach collection="list" index="index" item="item">
|
|
||||||
when id = #{item.id,jdbcType=INTEGER} then #{item.lossnum,jdbcType=INTEGER}
|
|
||||||
</foreach>
|
|
||||||
</trim>
|
|
||||||
<trim prefix="`status` = case" suffix="end,">
|
|
||||||
<foreach collection="list" index="index" item="item">
|
|
||||||
when id = #{item.id,jdbcType=INTEGER} then #{item.status,jdbcType=BOOLEAN}
|
|
||||||
</foreach>
|
|
||||||
</trim>
|
|
||||||
</trim>
|
|
||||||
where id in
|
|
||||||
<foreach close=")" collection="list" item="item" open="(" separator=", ">
|
|
||||||
#{item.id,jdbcType=INTEGER}
|
|
||||||
</foreach>
|
|
||||||
</update>
|
|
||||||
<insert id="batchInsert" keyColumn="id" keyProperty="id" parameterType="map" useGeneratedKeys="true">
|
|
||||||
<!--@mbg.generated-->
|
|
||||||
insert into inv_count_order_detail
|
|
||||||
(orderIdFk, productId, batchNo, produceDate, expireDate, serialNo, countNum, bookNum,
|
|
||||||
profitNum, lossNum, `status`)
|
|
||||||
values
|
|
||||||
<foreach collection="list" item="item" separator=",">
|
|
||||||
(#{item.orderidfk,jdbcType=VARCHAR}, #{item.productid,jdbcType=VARCHAR}, #{item.batchno,jdbcType=VARCHAR},
|
|
||||||
#{item.producedate,jdbcType=TIMESTAMP}, #{item.expiredate,jdbcType=TIMESTAMP},
|
|
||||||
#{item.serialno,jdbcType=VARCHAR}, #{item.countnum,jdbcType=INTEGER}, #{item.booknum,jdbcType=INTEGER},
|
|
||||||
#{item.profitnum,jdbcType=INTEGER}, #{item.lossnum,jdbcType=INTEGER}, #{item.status,jdbcType=BOOLEAN}
|
|
||||||
)
|
|
||||||
</foreach>
|
|
||||||
</insert>
|
|
||||||
</mapper>
|
</mapper>
|
Loading…
Reference in New Issue