You cannot select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
190 lines
7.7 KiB
XML
190 lines
7.7 KiB
XML
3 years ago
|
<?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.glxp.api.admin.dao.inventory.InvMaintenanceOrderDetailDao">
|
||
|
<resultMap id="BaseResultMap" type="com.glxp.api.admin.entity.inventory.InvMaintenanceOrderDetailEntity">
|
||
|
<id column="id" jdbcType="INTEGER" property="id"/>
|
||
|
<result column="orderIdFk" jdbcType="VARCHAR" property="orderIdFk"/>
|
||
|
<result column="code" jdbcType="VARCHAR" property="code"/>
|
||
|
<result column="productId" jdbcType="VARCHAR" property="productId"/>
|
||
|
<result column="nameCode" jdbcType="VARCHAR" property="nameCode"/>
|
||
|
<result column="batchNo" jdbcType="VARCHAR" property="batchNo"/>
|
||
|
<result column="produceDate" jdbcType="VARCHAR" property="produceDate"/>
|
||
|
<result column="expireDate" jdbcType="VARCHAR" property="expireDate"/>
|
||
|
<result column="count" jdbcType="INTEGER" property="count"/>
|
||
|
<result column="maintenanceStatus" jdbcType="BOOLEAN" property="maintenanceStatus"/>
|
||
|
<result column="deviceStatus" jdbcType="BOOLEAN" property="deviceStatus"/>
|
||
|
<result column="remark" jdbcType="VARCHAR" property="remark"/>
|
||
|
</resultMap>
|
||
|
|
||
|
<sql id="Base_Column_List">
|
||
|
id,
|
||
|
orderIdFk,
|
||
|
code,
|
||
|
productId,
|
||
|
nameCode,
|
||
|
batchNo,
|
||
|
produceDate,
|
||
|
expireDate,
|
||
|
`count`,
|
||
|
maintenanceStatus,
|
||
|
deviceStatus,
|
||
|
remark
|
||
|
</sql>
|
||
|
|
||
|
<select id="selectByPrimaryKey" parameterType="java.lang.Integer" resultMap="BaseResultMap">
|
||
|
select
|
||
|
<include refid="Base_Column_List"/>
|
||
|
from inv_maintenance_order_detail
|
||
|
where id = #{id,jdbcType=INTEGER}
|
||
|
</select>
|
||
|
|
||
|
<delete id="deleteByPrimaryKey" parameterType="java.lang.Integer">
|
||
|
delete
|
||
|
from inv_maintenance_order_detail
|
||
|
where id = #{id,jdbcType=INTEGER}
|
||
|
</delete>
|
||
|
|
||
|
<insert id="insert" keyColumn="id" keyProperty="id"
|
||
|
parameterType="com.glxp.api.admin.entity.inventory.InvMaintenanceOrderDetailEntity" useGeneratedKeys="true">
|
||
|
insert into inv_maintenance_order_detail (orderIdFk, code, productId,
|
||
|
nameCode, batchNo, produceDate,
|
||
|
expireDate, `count`, maintenanceStatus,
|
||
|
deviceStatus, remark)
|
||
|
values (#{orderIdFk,jdbcType=VARCHAR}, #{code,jdbcType=VARCHAR}, #{productId,jdbcType=VARCHAR},
|
||
|
#{nameCode,jdbcType=VARCHAR}, #{batchNo,jdbcType=VARCHAR}, #{produceDate,jdbcType=VARCHAR},
|
||
|
#{expireDate,jdbcType=VARCHAR}, #{count,jdbcType=INTEGER}, #{maintenanceStatus,jdbcType=BOOLEAN},
|
||
|
#{deviceStatus,jdbcType=BOOLEAN}, #{remark,jdbcType=VARCHAR})
|
||
|
</insert>
|
||
|
|
||
|
<insert id="insertSelective" keyColumn="id" keyProperty="id"
|
||
|
parameterType="com.glxp.api.admin.entity.inventory.InvMaintenanceOrderDetailEntity" useGeneratedKeys="true">
|
||
|
insert into inv_maintenance_order_detail
|
||
|
<trim prefix="(" suffix=")" suffixOverrides=",">
|
||
|
<if test="orderIdFk != null">
|
||
|
orderIdFk,
|
||
|
</if>
|
||
|
<if test="code != null">
|
||
|
code,
|
||
|
</if>
|
||
|
<if test="productId != null">
|
||
|
productId,
|
||
|
</if>
|
||
|
<if test="nameCode != null">
|
||
|
nameCode,
|
||
|
</if>
|
||
|
<if test="batchNo != null">
|
||
|
batchNo,
|
||
|
</if>
|
||
|
<if test="produceDate != null">
|
||
|
produceDate,
|
||
|
</if>
|
||
|
<if test="expireDate != null">
|
||
|
expireDate,
|
||
|
</if>
|
||
|
<if test="count != null">
|
||
|
`count`,
|
||
|
</if>
|
||
|
<if test="maintenanceStatus != null">
|
||
|
maintenanceStatus,
|
||
|
</if>
|
||
|
<if test="deviceStatus != null">
|
||
|
deviceStatus,
|
||
|
</if>
|
||
|
<if test="remark != null">
|
||
|
remark,
|
||
|
</if>
|
||
|
</trim>
|
||
|
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
||
|
<if test="orderIdFk != null">
|
||
|
#{orderIdFk,jdbcType=VARCHAR},
|
||
|
</if>
|
||
|
<if test="code != null">
|
||
|
#{code,jdbcType=VARCHAR},
|
||
|
</if>
|
||
|
<if test="productId != null">
|
||
|
#{productId,jdbcType=VARCHAR},
|
||
|
</if>
|
||
|
<if test="nameCode != null">
|
||
|
#{nameCode,jdbcType=VARCHAR},
|
||
|
</if>
|
||
|
<if test="batchNo != null">
|
||
|
#{batchNo,jdbcType=VARCHAR},
|
||
|
</if>
|
||
|
<if test="produceDate != null">
|
||
|
#{produceDate,jdbcType=VARCHAR},
|
||
|
</if>
|
||
|
<if test="expireDate != null">
|
||
|
#{expireDate,jdbcType=VARCHAR},
|
||
|
</if>
|
||
|
<if test="count != null">
|
||
|
#{count,jdbcType=INTEGER},
|
||
|
</if>
|
||
|
<if test="maintenanceStatus != null">
|
||
|
#{maintenanceStatus,jdbcType=BOOLEAN},
|
||
|
</if>
|
||
|
<if test="deviceStatus != null">
|
||
|
#{deviceStatus,jdbcType=BOOLEAN},
|
||
|
</if>
|
||
|
<if test="remark != null">
|
||
|
#{remark,jdbcType=VARCHAR},
|
||
|
</if>
|
||
|
</trim>
|
||
|
</insert>
|
||
|
|
||
|
<update id="updateByPrimaryKeySelective"
|
||
|
parameterType="com.glxp.api.admin.entity.inventory.InvMaintenanceOrderDetailEntity">
|
||
|
update inv_maintenance_order_detail
|
||
|
<set>
|
||
|
<if test="orderIdFk != null">
|
||
|
orderIdFk = #{orderIdFk,jdbcType=VARCHAR},
|
||
|
</if>
|
||
|
<if test="code != null">
|
||
|
code = #{code,jdbcType=VARCHAR},
|
||
|
</if>
|
||
|
<if test="productId != null">
|
||
|
productId = #{productId,jdbcType=VARCHAR},
|
||
|
</if>
|
||
|
<if test="nameCode != null">
|
||
|
nameCode = #{nameCode,jdbcType=VARCHAR},
|
||
|
</if>
|
||
|
<if test="batchNo != null">
|
||
|
batchNo = #{batchNo,jdbcType=VARCHAR},
|
||
|
</if>
|
||
|
<if test="produceDate != null">
|
||
|
produceDate = #{produceDate,jdbcType=VARCHAR},
|
||
|
</if>
|
||
|
<if test="expireDate != null">
|
||
|
expireDate = #{expireDate,jdbcType=VARCHAR},
|
||
|
</if>
|
||
|
<if test="count != null">
|
||
|
`count` = #{count,jdbcType=INTEGER},
|
||
|
</if>
|
||
|
<if test="maintenanceStatus != null">
|
||
|
maintenanceStatus = #{maintenanceStatus,jdbcType=BOOLEAN},
|
||
|
</if>
|
||
|
<if test="deviceStatus != null">
|
||
|
deviceStatus = #{deviceStatus,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.InvMaintenanceOrderDetailEntity">
|
||
|
update inv_maintenance_order_detail
|
||
|
set orderIdFk = #{orderIdFk,jdbcType=VARCHAR},
|
||
|
code = #{code,jdbcType=VARCHAR},
|
||
|
productId = #{productId,jdbcType=VARCHAR},
|
||
|
nameCode = #{nameCode,jdbcType=VARCHAR},
|
||
|
batchNo = #{batchNo,jdbcType=VARCHAR},
|
||
|
produceDate = #{produceDate,jdbcType=VARCHAR},
|
||
|
expireDate = #{expireDate,jdbcType=VARCHAR},
|
||
|
`count` = #{count,jdbcType=INTEGER},
|
||
|
maintenanceStatus = #{maintenanceStatus,jdbcType=BOOLEAN},
|
||
|
deviceStatus = #{deviceStatus,jdbcType=BOOLEAN},
|
||
|
remark = #{remark,jdbcType=VARCHAR}
|
||
|
where id = #{id,jdbcType=INTEGER}
|
||
|
</update>
|
||
|
</mapper>
|