|
@@ -0,0 +1,101 @@
|
|
|
+<?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.SysDragTableStyleMapper">
|
|
|
+
|
|
|
+ <resultMap type="SysDragTableStyle" id="SysDragTableStyleResult">
|
|
|
+ <result property="id" column="id" />
|
|
|
+ <result property="styleKey" column="style_key" />
|
|
|
+ <result property="styleName" column="style_name" />
|
|
|
+ <result property="styleType" column="style_type" />
|
|
|
+ <result property="styleCode" column="style_code" />
|
|
|
+ <result property="styleDescription" column="style_description" />
|
|
|
+ <result property="styleStatus" column="style_status" />
|
|
|
+ <result property="delFlag" column="del_flag" />
|
|
|
+ <result property="createBy" column="create_by" />
|
|
|
+ <result property="createById" column="create_by_id" />
|
|
|
+ <result property="createTime" column="create_time" />
|
|
|
+ <result property="updateBy" column="update_by" />
|
|
|
+ <result property="updateById" column="update_by_id" />
|
|
|
+ <result property="updateTime" column="update_time" />
|
|
|
+ </resultMap>
|
|
|
+
|
|
|
+ <sql id="selectSysDragTableStyleVo">
|
|
|
+ select id, style_key, style_name, style_type, style_code, style_description, style_status, del_flag, create_by, create_by_id, create_time, update_by, update_by_id, update_time from sys_drag_table_style
|
|
|
+ </sql>
|
|
|
+
|
|
|
+ <select id="selectSysDragTableStyleList" parameterType="SysDragTableStyle" resultMap="SysDragTableStyleResult">
|
|
|
+ <include refid="selectSysDragTableStyleVo"/>
|
|
|
+ where del_flag = '0'
|
|
|
+ <if test="styleKey != null and styleKey != ''"> and style_key = #{styleKey}</if>
|
|
|
+ <if test="styleName != null and styleName != ''"> and style_name like concat('%', #{styleName}, '%')</if>
|
|
|
+ <if test="styleType != null "> and style_type = #{styleType}</if>
|
|
|
+ <if test="styleCode != null and styleCode != ''"> and style_code = #{styleCode}</if>
|
|
|
+ <if test="styleDescription != null and styleDescription != ''"> and style_description = #{styleDescription}</if>
|
|
|
+ <if test="styleStatus != null and styleStatus != ''"> and style_status = #{styleStatus}</if>
|
|
|
+ <if test="createById != null "> and create_by_id = #{createById}</if>
|
|
|
+ <if test="updateById != null "> and update_by_id = #{updateById}</if>
|
|
|
+ order by create_time desc
|
|
|
+ </select>
|
|
|
+
|
|
|
+ <select id="selectSysDragTableStyleById" parameterType="Long" resultMap="SysDragTableStyleResult">
|
|
|
+ <include refid="selectSysDragTableStyleVo"/>
|
|
|
+ where id = #{id}
|
|
|
+ </select>
|
|
|
+
|
|
|
+ <insert id="insertSysDragTableStyle" parameterType="SysDragTableStyle">
|
|
|
+ insert into sys_drag_table_style
|
|
|
+ <trim prefix="(" suffix=")" suffixOverrides=",">
|
|
|
+ <if test="styleKey != null">style_key,</if>
|
|
|
+ <if test="styleName != null">style_name,</if>
|
|
|
+ <if test="styleType != null">style_type,</if>
|
|
|
+ <if test="styleCode != null">style_code,</if>
|
|
|
+ <if test="styleDescription != null">style_description,</if>
|
|
|
+ <if test="styleStatus != null">style_status,</if>
|
|
|
+ <if test="createBy != null">create_by,</if>
|
|
|
+ <if test="createById != null">create_by_id,</if>
|
|
|
+ <if test="createTime != null">create_time,</if>
|
|
|
+ del_flag
|
|
|
+ </trim>
|
|
|
+ <trim prefix="values (" suffix=")" suffixOverrides=",">
|
|
|
+ <if test="styleKey != null">#{styleKey},</if>
|
|
|
+ <if test="styleName != null">#{styleName},</if>
|
|
|
+ <if test="styleType != null">#{styleType},</if>
|
|
|
+ <if test="styleCode != null">#{styleCode},</if>
|
|
|
+ <if test="styleDescription != null">#{styleDescription},</if>
|
|
|
+ <if test="styleStatus != null">#{styleStatus},</if>
|
|
|
+ <if test="createBy != null">#{createBy},</if>
|
|
|
+ <if test="createById != null">#{createById},</if>
|
|
|
+ <if test="createTime != null">#{createTime},</if>
|
|
|
+ '0'
|
|
|
+ </trim>
|
|
|
+ </insert>
|
|
|
+
|
|
|
+ <update id="updateSysDragTableStyle" parameterType="SysDragTableStyle">
|
|
|
+ update sys_drag_table_style
|
|
|
+ <trim prefix="SET" suffixOverrides=",">
|
|
|
+ <if test="styleKey != null">style_key = #{styleKey},</if>
|
|
|
+ <if test="styleName != null">style_name = #{styleName},</if>
|
|
|
+ <if test="styleType != null">style_type = #{styleType},</if>
|
|
|
+ <if test="styleCode != null">style_code = #{styleCode},</if>
|
|
|
+ <if test="styleDescription != null">style_description = #{styleDescription},</if>
|
|
|
+ <if test="styleStatus != null">style_status = #{styleStatus},</if>
|
|
|
+ <if test="updateBy != null">update_by = #{updateBy},</if>
|
|
|
+ <if test="updateById != null">update_by_id = #{updateById},</if>
|
|
|
+ <if test="updateTime != null">update_time = #{updateTime},</if>
|
|
|
+ </trim>
|
|
|
+ where id = #{id}
|
|
|
+ </update>
|
|
|
+
|
|
|
+ <update id="deleteSysDragTableStyleById" parameterType="Long">
|
|
|
+ update sys_drag_table_style set del_flag = '2' where id = #{id}
|
|
|
+ </update>
|
|
|
+
|
|
|
+ <update id="deleteSysDragTableStyleByIds" parameterType="String">
|
|
|
+ update sys_drag_table_style set del_flag = '2' where id in
|
|
|
+ <foreach item="id" collection="array" open="(" separator="," close=")">
|
|
|
+ #{id}
|
|
|
+ </foreach>
|
|
|
+ </update>
|
|
|
+</mapper>
|