|
@@ -7,6 +7,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
<resultMap type="PosAppeal" id="PosAppealResult">
|
|
<resultMap type="PosAppeal" id="PosAppealResult">
|
|
|
<result property="id" column="id" />
|
|
<result property="id" column="id" />
|
|
|
<result property="ddId" column="dd_id" />
|
|
<result property="ddId" column="dd_id" />
|
|
|
|
|
+ <result property="userId" column="user_id" />
|
|
|
<result property="userType" column="user_type" />
|
|
<result property="userType" column="user_type" />
|
|
|
<result property="nickName" column="nick_name" />
|
|
<result property="nickName" column="nick_name" />
|
|
|
<result property="content" column="content" />
|
|
<result property="content" column="content" />
|
|
@@ -16,13 +17,14 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
</resultMap>
|
|
</resultMap>
|
|
|
|
|
|
|
|
<sql id="selectPosAppealVo">
|
|
<sql id="selectPosAppealVo">
|
|
|
- select id, dd_id, user_type, nick_name, content, imgs,feed_back,use_case from pos_appeal
|
|
|
|
|
|
|
+ select id, dd_id, user_id, user_type, nick_name, content, imgs,feed_back,use_case from pos_appeal
|
|
|
</sql>
|
|
</sql>
|
|
|
|
|
|
|
|
<select id="selectPosAppealList" parameterType="PosAppeal" resultMap="PosAppealResult">
|
|
<select id="selectPosAppealList" parameterType="PosAppeal" resultMap="PosAppealResult">
|
|
|
<include refid="selectPosAppealVo"/>
|
|
<include refid="selectPosAppealVo"/>
|
|
|
<where>
|
|
<where>
|
|
|
<if test="ddId != null "> and dd_id = #{ddId}</if>
|
|
<if test="ddId != null "> and dd_id = #{ddId}</if>
|
|
|
|
|
+ <if test="userId != null "> and user_id = #{userId}</if>
|
|
|
<if test="userType != null and userType != ''"> and user_type = #{userType}</if>
|
|
<if test="userType != null and userType != ''"> and user_type = #{userType}</if>
|
|
|
</where>
|
|
</where>
|
|
|
order by dd_id asc,user_type asc,create_time desc
|
|
order by dd_id asc,user_type asc,create_time desc
|
|
@@ -37,6 +39,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
insert into pos_appeal
|
|
insert into pos_appeal
|
|
|
<trim prefix="(" suffix=")" suffixOverrides=",">
|
|
<trim prefix="(" suffix=")" suffixOverrides=",">
|
|
|
<if test="ddId != null">dd_id,</if>
|
|
<if test="ddId != null">dd_id,</if>
|
|
|
|
|
+ <if test="userId != null">user_id,</if>
|
|
|
<if test="userType != null">user_type,</if>
|
|
<if test="userType != null">user_type,</if>
|
|
|
<if test="nickName != null">nick_name,</if>
|
|
<if test="nickName != null">nick_name,</if>
|
|
|
<if test="content != null">content,</if>
|
|
<if test="content != null">content,</if>
|
|
@@ -46,6 +49,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
</trim>
|
|
</trim>
|
|
|
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
|
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
|
|
<if test="ddId != null">#{ddId},</if>
|
|
<if test="ddId != null">#{ddId},</if>
|
|
|
|
|
+ <if test="userId != null">#{userId},</if>
|
|
|
<if test="userType != null">#{userType},</if>
|
|
<if test="userType != null">#{userType},</if>
|
|
|
<if test="nickName != null">#{nickName},</if>
|
|
<if test="nickName != null">#{nickName},</if>
|
|
|
<if test="content != null">#{content},</if>
|
|
<if test="content != null">#{content},</if>
|
|
@@ -59,6 +63,7 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
update pos_appeal
|
|
update pos_appeal
|
|
|
<trim prefix="SET" suffixOverrides=",">
|
|
<trim prefix="SET" suffixOverrides=",">
|
|
|
<if test="ddId != null">dd_id = #{ddId},</if>
|
|
<if test="ddId != null">dd_id = #{ddId},</if>
|
|
|
|
|
+ <if test="userId != null">user_id = #{userId},</if>
|
|
|
<if test="userType != null">user_type = #{userType},</if>
|
|
<if test="userType != null">user_type = #{userType},</if>
|
|
|
<if test="nickName != null">nick_name = #{nickName},</if>
|
|
<if test="nickName != null">nick_name = #{nickName},</if>
|
|
|
<if test="content != null">content = #{content},</if>
|
|
<if test="content != null">content = #{content},</if>
|