90 lines
4.1 KiB
XML
90 lines
4.1 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.ruoyi.system.mapper.EtAdminOrderHistoryMapper">
|
|
|
|
<resultMap type="EtAdminOrderHistory" id="EtAdminOrderHistoryResult">
|
|
<result property="id" column="id" />
|
|
<result property="orderNo" column="order_no" />
|
|
<result property="userId" column="user_id" />
|
|
<result property="userName" column="user_name" />
|
|
<result property="status" column="status" />
|
|
<result property="info" column="info" />
|
|
<result property="type" column="type" />
|
|
<result property="operationType" column="operation_type" />
|
|
<result property="createTime" column="create_time" />
|
|
</resultMap>
|
|
|
|
<sql id="selectEtAdminOrderHistoryVo">
|
|
select id, order_no, user_id, user_name, status, info, type, operation_type, create_time from et_admin_order_history
|
|
</sql>
|
|
|
|
<select id="selectEtAdminOrderHistoryList" parameterType="EtAdminOrderHistory" resultMap="EtAdminOrderHistoryResult">
|
|
<include refid="selectEtAdminOrderHistoryVo"/>
|
|
<where>
|
|
<if test="orderNo != null and orderNo != ''"> and order_no = #{orderNo}</if>
|
|
<if test="status != null and status != ''"> and status = #{status}</if>
|
|
<if test="info != null and info != ''"> and info = #{info}</if>
|
|
<if test="type != null and type != ''"> and type = #{type}</if>
|
|
</where>
|
|
</select>
|
|
|
|
<select id="selectEtAdminOrderHistoryById" parameterType="Long" resultMap="EtAdminOrderHistoryResult">
|
|
<include refid="selectEtAdminOrderHistoryVo"/>
|
|
where id = #{id}
|
|
</select>
|
|
|
|
<insert id="insertEtAdminOrderHistory" parameterType="EtAdminOrderHistory">
|
|
insert into et_admin_order_history
|
|
<trim prefix="(" suffix=")" suffixOverrides=",">
|
|
<if test="id != null">id,</if>
|
|
<if test="orderNo != null">order_no,</if>
|
|
<if test="userId != null">user_id,</if>
|
|
<if test="userName != null">user_name,</if>
|
|
<if test="status != null">status,</if>
|
|
<if test="info != null">info,</if>
|
|
<if test="type != null">type,</if>
|
|
<if test="operationType != null">operation_type,</if>
|
|
<if test="createTime != null">create_time,</if>
|
|
</trim>
|
|
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
|
<if test="id != null">#{id},</if>
|
|
<if test="orderNo != null">#{orderNo},</if>
|
|
<if test="userId != null">#{userId},</if>
|
|
<if test="userName != null">#{userName},</if>
|
|
<if test="status != null">#{status},</if>
|
|
<if test="info != null">#{info},</if>
|
|
<if test="type != null">#{type},</if>
|
|
<if test="operationType != null">#{operationType},</if>
|
|
<if test="createTime != null">#{createTime},</if>
|
|
</trim>
|
|
</insert>
|
|
|
|
<update id="updateEtAdminOrderHistory" parameterType="EtAdminOrderHistory">
|
|
update et_admin_order_history
|
|
<trim prefix="SET" suffixOverrides=",">
|
|
<if test="orderNo != null">order_no = #{orderNo},</if>
|
|
<if test="userId != null">user_id = #{userId},</if>
|
|
<if test="userName != null">user_name = #{userName},</if>
|
|
<if test="status != null">status = #{status},</if>
|
|
<if test="info != null">info = #{info},</if>
|
|
<if test="type != null">type = #{type},</if>
|
|
<if test="operationType != null">operation_type = #{operationType},</if>
|
|
<if test="createTime != null">create_time = #{createTime},</if>
|
|
</trim>
|
|
where id = #{id}
|
|
</update>
|
|
|
|
<delete id="deleteEtAdminOrderHistoryById" parameterType="Long">
|
|
delete from et_admin_order_history where id = #{id}
|
|
</delete>
|
|
|
|
<delete id="deleteEtAdminOrderHistoryByIds" parameterType="String">
|
|
delete from et_admin_order_history where id in
|
|
<foreach item="id" collection="array" open="(" separator="," close=")">
|
|
#{id}
|
|
</foreach>
|
|
</delete>
|
|
</mapper>
|