91 lines
3.5 KiB
XML
91 lines
3.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.zhwl.hotel.homestay.order.mapper.ZdyHotelHomestayOrderLogMapper">
|
|
|
|
<resultMap type="ZdyHotelHomestayOrderLog" id="ZdyHotelHomestayOrderLogResult">
|
|
<result property="id" column="id"/>
|
|
<result property="orderId" column="order_id"/>
|
|
<result property="statusType" column="status_type"/>
|
|
<result property="statusValue" column="status_value"/>
|
|
<result property="createZdyUserId" column="create_zdy_user_id"/>
|
|
<result property="createSysUserId" column="create_sys_user_id"/>
|
|
<result property="content" column="content"/>
|
|
<result property="createTime" column="create_time"/>
|
|
</resultMap>
|
|
|
|
<sql id="selectZdyHotelHomestayOrderLogVo">
|
|
select id,
|
|
order_id,
|
|
status_type,
|
|
status_value,
|
|
create_zdy_user_id,
|
|
create_sys_user_id,
|
|
content,
|
|
create_time
|
|
from zdy_hotel_homestay_order_log
|
|
</sql>
|
|
|
|
<select id="selectZdyHotelHomestayOrderLogList" parameterType="ZdyHotelHomestayOrderLog"
|
|
resultMap="ZdyHotelHomestayOrderLogResult">
|
|
<include refid="selectZdyHotelHomestayOrderLogVo"/>
|
|
<where>
|
|
<if test="orderId != null ">
|
|
and order_id = #{orderId}
|
|
</if>
|
|
<if test="statusType != null and statusType != ''">
|
|
and status_type = #{statusType}
|
|
</if>
|
|
<if test="statusValue != null and statusValue != ''">
|
|
and status_value = #{statusValue}
|
|
</if>
|
|
<if test="createZdyUserId != null ">
|
|
and create_zdy_user_id = #{createZdyUserId}
|
|
</if>
|
|
<if test="createSysUserId != null ">
|
|
and create_sys_user_id = #{createSysUserId}
|
|
</if>
|
|
<if test="content != null and content != ''">
|
|
and content = #{content}
|
|
</if>
|
|
</where>
|
|
</select>
|
|
|
|
<insert id="insertZdyHotelHomestayOrderLog" parameterType="ZdyHotelHomestayOrderLog" useGeneratedKeys="true"
|
|
keyProperty="id">
|
|
insert into zdy_hotel_homestay_order_log
|
|
<trim prefix="(" suffix=")" suffixOverrides=",">
|
|
<if test="orderId != null">order_id,
|
|
</if>
|
|
<if test="statusType != null">status_type,
|
|
</if>
|
|
<if test="statusValue != null">status_value,
|
|
</if>
|
|
<if test="createZdyUserId != null">create_zdy_user_id,
|
|
</if>
|
|
<if test="createSysUserId != null">create_sys_user_id,
|
|
</if>
|
|
<if test="content != null">content,
|
|
</if>
|
|
<if test="createTime != null">create_time,
|
|
</if>
|
|
</trim>
|
|
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
|
<if test="orderId != null">#{orderId},
|
|
</if>
|
|
<if test="statusType != null">#{statusType},
|
|
</if>
|
|
<if test="statusValue != null">#{statusValue},
|
|
</if>
|
|
<if test="createZdyUserId != null">#{createZdyUserId},
|
|
</if>
|
|
<if test="createSysUserId != null">#{createSysUserId},
|
|
</if>
|
|
<if test="content != null">#{content},
|
|
</if>
|
|
<if test="createTime != null">#{createTime},
|
|
</if>
|
|
</trim>
|
|
</insert>
|
|
</mapper> |