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.
168 lines
6.5 KiB
XML
168 lines
6.5 KiB
XML
<?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.DeviceMAOrderDao">
|
|
<resultMap id="BaseResultMap" type="com.glxp.api.admin.entity.inventory.DeviceMAOrderEntity">
|
|
<id column="id" jdbcType="INTEGER" property="id"/>
|
|
<result column="orderId" jdbcType="VARCHAR" property="orderId"/>
|
|
<result column="collOrderId" jdbcType="VARCHAR" property="collOrderId"/>
|
|
<result column="createTime" jdbcType="VARCHAR" property="createTime"/>
|
|
<result column="updateTime" jdbcType="VARCHAR" property="updateTime"/>
|
|
<result column="createUser" jdbcType="VARCHAR" property="createUser"/>
|
|
<result column="auditUser" jdbcType="VARCHAR" property="auditUser"/>
|
|
<result column="remark" jdbcType="VARCHAR" property="remark"/>
|
|
<result column="status" jdbcType="BOOLEAN" property="status"/>
|
|
</resultMap>
|
|
|
|
<sql id="Base_Column_List">
|
|
id,
|
|
orderId,
|
|
collOrderId,
|
|
createTime,
|
|
updateTime,
|
|
`createUser`,
|
|
auditUser,
|
|
remark,
|
|
`status`
|
|
</sql>
|
|
|
|
<select id="selectByPrimaryKey" parameterType="java.lang.Integer" resultMap="BaseResultMap">
|
|
select
|
|
<include refid="Base_Column_List"/>
|
|
from device_ma_order
|
|
where id = #{id,jdbcType=INTEGER}
|
|
</select>
|
|
|
|
<delete id="deleteByPrimaryKey" parameterType="java.lang.Integer">
|
|
delete
|
|
from device_ma_order
|
|
where id = #{id,jdbcType=INTEGER}
|
|
</delete>
|
|
|
|
<insert id="insert" keyColumn="id" keyProperty="id"
|
|
parameterType="com.glxp.api.admin.entity.inventory.DeviceMAOrderEntity" useGeneratedKeys="true">
|
|
insert into device_ma_order (orderId, collOrderId, createTime,
|
|
updateTime, `createUser`, auditUser,
|
|
remark, `status`)
|
|
values (#{orderId,jdbcType=VARCHAR}, #{collOrderId,jdbcType=VARCHAR}, #{createTime,jdbcType=VARCHAR},
|
|
#{updateTime,jdbcType=VARCHAR}, #{createUser,jdbcType=VARCHAR}, #{auditUser,jdbcType=VARCHAR},
|
|
#{remark,jdbcType=VARCHAR}, #{status,jdbcType=BOOLEAN})
|
|
</insert>
|
|
|
|
<insert id="insertSelective" keyColumn="id" keyProperty="id"
|
|
parameterType="com.glxp.api.admin.entity.inventory.DeviceMAOrderEntity" useGeneratedKeys="true">
|
|
insert into device_ma_order
|
|
<trim prefix="(" suffix=")" suffixOverrides=",">
|
|
<if test="orderId != null">
|
|
orderId,
|
|
</if>
|
|
<if test="collOrderId != null">
|
|
collOrderId,
|
|
</if>
|
|
<if test="createTime != null">
|
|
createTime,
|
|
</if>
|
|
<if test="updateTime != null">
|
|
updateTime,
|
|
</if>
|
|
<if test="createUser != null">
|
|
`createUser`,
|
|
</if>
|
|
<if test="auditUser != null">
|
|
auditUser,
|
|
</if>
|
|
<if test="remark != null">
|
|
remark,
|
|
</if>
|
|
<if test="status != null">
|
|
`status`,
|
|
</if>
|
|
</trim>
|
|
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
|
<if test="orderId != null">
|
|
#{orderId,jdbcType=VARCHAR},
|
|
</if>
|
|
<if test="collOrderId != null">
|
|
#{collOrderId,jdbcType=VARCHAR},
|
|
</if>
|
|
<if test="createTime != null">
|
|
#{createTime,jdbcType=VARCHAR},
|
|
</if>
|
|
<if test="updateTime != null">
|
|
#{updateTime,jdbcType=VARCHAR},
|
|
</if>
|
|
<if test="createUser != null">
|
|
#{createUser,jdbcType=VARCHAR},
|
|
</if>
|
|
<if test="auditUser != null">
|
|
#{auditUser,jdbcType=VARCHAR},
|
|
</if>
|
|
<if test="remark != null">
|
|
#{remark,jdbcType=VARCHAR},
|
|
</if>
|
|
<if test="status != null">
|
|
#{status,jdbcType=BOOLEAN},
|
|
</if>
|
|
</trim>
|
|
</insert>
|
|
|
|
<update id="updateByPrimaryKeySelective" parameterType="com.glxp.api.admin.entity.inventory.DeviceMAOrderEntity">
|
|
update device_ma_order
|
|
<set>
|
|
<if test="orderId != null">
|
|
orderId = #{orderId,jdbcType=VARCHAR},
|
|
</if>
|
|
<if test="collOrderId != null">
|
|
collOrderId = #{collOrderId,jdbcType=VARCHAR},
|
|
</if>
|
|
<if test="createTime != null">
|
|
createTime = #{createTime,jdbcType=VARCHAR},
|
|
</if>
|
|
<if test="updateTime != null">
|
|
updateTime = #{updateTime,jdbcType=VARCHAR},
|
|
</if>
|
|
<if test="createUser != null">
|
|
`createUser` = #{createUser,jdbcType=VARCHAR},
|
|
</if>
|
|
<if test="auditUser != null">
|
|
auditUser = #{auditUser,jdbcType=VARCHAR},
|
|
</if>
|
|
<if test="remark != null">
|
|
remark = #{remark,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.DeviceMAOrderEntity">
|
|
update device_ma_order
|
|
set orderId = #{orderId,jdbcType=VARCHAR},
|
|
collOrderId = #{collOrderId,jdbcType=VARCHAR},
|
|
createTime = #{createTime,jdbcType=VARCHAR},
|
|
updateTime = #{updateTime,jdbcType=VARCHAR},
|
|
`createUser` = #{createUser,jdbcType=VARCHAR},
|
|
auditUser = #{auditUser,jdbcType=VARCHAR},
|
|
remark = #{remark,jdbcType=VARCHAR},
|
|
`status` = #{status,jdbcType=BOOLEAN}
|
|
where id = #{id,jdbcType=INTEGER}
|
|
</update>
|
|
|
|
<select id="filterList" resultType="com.glxp.api.admin.entity.inventory.DeviceMAOrderEntity">
|
|
select
|
|
<include refid="Base_Column_List"/>
|
|
from device_ma_order
|
|
<where>
|
|
<if test="orderId != null and orderId != ''">
|
|
AND orderId like concat('%', #{orderId}, '%')
|
|
</if>
|
|
<if test="status != null">
|
|
AND status = #{status}
|
|
</if>
|
|
<if test="collOrderId != null and collOrderId != ''">
|
|
AND collOrderId like concat('%', #{collOrderId}, '%')
|
|
</if>
|
|
</where>
|
|
</select>
|
|
</mapper> |