|
@@ -3,43 +3,40 @@
|
|
|
PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
"http://mybatis.org/dtd/mybatis-3-mapper.dtd">
|
|
|
<mapper namespace="com.fs.course.mapper.FsUserCourseComplaintTypeMapper">
|
|
|
-
|
|
|
+
|
|
|
<resultMap type="FsUserCourseComplaintType" id="FsUserCourseComplaintTypeResult">
|
|
|
<result property="complaintTypeId" column="complaint_type_id" />
|
|
|
<result property="parentId" column="parent_id" />
|
|
|
<result property="complaintTypeName" column="complaint_type_name" />
|
|
|
<result property="typeLevel" column="type_level" />
|
|
|
- <result property="isDel" column="is_del" />
|
|
|
<result property="createTime" column="create_time" />
|
|
|
<result property="updateTime" column="update_time" />
|
|
|
</resultMap>
|
|
|
|
|
|
<sql id="selectFsUserCourseComplaintTypeVo">
|
|
|
- select complaint_type_id, parent_id, complaint_type_name, type_level, is_del, create_time, update_time from fs_user_course_complaint_type
|
|
|
+ select complaint_type_id, parent_id, complaint_type_name, type_level, create_time, update_time from fs_user_course_complaint_type
|
|
|
</sql>
|
|
|
|
|
|
<select id="selectFsUserCourseComplaintTypeList" parameterType="FsUserCourseComplaintType" resultMap="FsUserCourseComplaintTypeResult">
|
|
|
<include refid="selectFsUserCourseComplaintTypeVo"/>
|
|
|
- <where>
|
|
|
+ <where>
|
|
|
<if test="parentId != null "> and parent_id = #{parentId}</if>
|
|
|
<if test="complaintTypeName != null and complaintTypeName != ''"> and complaint_type_name like concat('%', #{complaintTypeName}, '%')</if>
|
|
|
<if test="typeLevel != null "> and type_level = #{typeLevel}</if>
|
|
|
- <if test="isDel != null "> and is_del = #{isDel}</if>
|
|
|
</where>
|
|
|
</select>
|
|
|
-
|
|
|
+
|
|
|
<select id="selectFsUserCourseComplaintTypeByComplaintTypeId" parameterType="Long" resultMap="FsUserCourseComplaintTypeResult">
|
|
|
<include refid="selectFsUserCourseComplaintTypeVo"/>
|
|
|
where complaint_type_id = #{complaintTypeId}
|
|
|
</select>
|
|
|
-
|
|
|
+
|
|
|
<insert id="insertFsUserCourseComplaintType" parameterType="FsUserCourseComplaintType" useGeneratedKeys="true" keyProperty="complaintTypeId">
|
|
|
insert into fs_user_course_complaint_type
|
|
|
<trim prefix="(" suffix=")" suffixOverrides=",">
|
|
|
<if test="parentId != null">parent_id,</if>
|
|
|
<if test="complaintTypeName != null">complaint_type_name,</if>
|
|
|
<if test="typeLevel != null">type_level,</if>
|
|
|
- <if test="isDel != null">is_del,</if>
|
|
|
<if test="createTime != null">create_time,</if>
|
|
|
<if test="updateTime != null">update_time,</if>
|
|
|
</trim>
|
|
@@ -47,7 +44,6 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
<if test="parentId != null">#{parentId},</if>
|
|
|
<if test="complaintTypeName != null">#{complaintTypeName},</if>
|
|
|
<if test="typeLevel != null">#{typeLevel},</if>
|
|
|
- <if test="isDel != null">#{isDel},</if>
|
|
|
<if test="createTime != null">#{createTime},</if>
|
|
|
<if test="updateTime != null">#{updateTime},</if>
|
|
|
</trim>
|
|
@@ -59,7 +55,6 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
<if test="parentId != null">parent_id = #{parentId},</if>
|
|
|
<if test="complaintTypeName != null">complaint_type_name = #{complaintTypeName},</if>
|
|
|
<if test="typeLevel != null">type_level = #{typeLevel},</if>
|
|
|
- <if test="isDel != null">is_del = #{isDel},</if>
|
|
|
<if test="createTime != null">create_time = #{createTime},</if>
|
|
|
<if test="updateTime != null">update_time = #{updateTime},</if>
|
|
|
</trim>
|
|
@@ -71,9 +66,9 @@ PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
|
|
|
</delete>
|
|
|
|
|
|
<delete id="deleteFsUserCourseComplaintTypeByComplaintTypeIds" parameterType="String">
|
|
|
- delete from fs_user_course_complaint_type where complaint_type_id in
|
|
|
+ delete from fs_user_course_complaint_type where complaint_type_id in
|
|
|
<foreach item="complaintTypeId" collection="array" open="(" separator="," close=")">
|
|
|
#{complaintTypeId}
|
|
|
</foreach>
|
|
|
</delete>
|
|
|
-</mapper>
|
|
|
+</mapper>
|