<?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.landtool.lanbase.modules.res.dao.Res_ThemeTypeMapper" >
|
<resultMap id="BaseResultMap" type="com.landtool.lanbase.modules.res.entity.Res_ThemeType" >
|
<id column="TYPEID" property="typeid" jdbcType="INTEGER" />
|
<result column="TITLE" property="title" jdbcType="VARCHAR" />
|
<result column="CONTENT" property="content" jdbcType="VARCHAR" />
|
<result column="ADDUSERID" property="adduserid" jdbcType="INTEGER" />
|
<result column="ADDTIME" property="addtime" jdbcType="TIMESTAMP" />
|
<result column="ORDERINDEX" property="orderindex" jdbcType="INTEGER" />
|
<result column="THEMES" property="themes" jdbcType="VARCHAR" />
|
<result column="ISDEFAULT" property="isdefault" jdbcType="TINYINT" />
|
</resultMap>
|
<sql id="Base_Column_List" >
|
TYPEID, TITLE, CONTENT, ADDUSERID, ADDTIME, ORDERINDEX, THEMES, ISDEFAULT
|
</sql>
|
<select id="selectByPrimaryKey" resultMap="BaseResultMap" parameterType="java.lang.Integer" >
|
select
|
<include refid="Base_Column_List" />
|
from RES_THEMETYPE
|
where TYPEID = #{typeid,jdbcType=INTEGER}
|
</select>
|
<delete id="deleteByPrimaryKey" parameterType="java.lang.Integer" >
|
delete from RES_THEMETYPE
|
where TYPEID = #{typeid,jdbcType=INTEGER}
|
</delete>
|
<insert id="insert" parameterType="com.landtool.lanbase.modules.res.entity.Res_ThemeType" >
|
insert into RES_THEMETYPE (TYPEID, TITLE, CONTENT,
|
ADDUSERID, ADDTIME, ORDERINDEX,
|
THEMES, ISDEFAULT)
|
values (#{typeid,jdbcType=INTEGER}, #{title,jdbcType=VARCHAR}, #{content,jdbcType=VARCHAR},
|
#{adduserid,jdbcType=INTEGER}, #{addtime,jdbcType=TIMESTAMP}, #{orderindex,jdbcType=INTEGER},
|
#{themes,jdbcType=VARCHAR}, #{isdefault,jdbcType=TINYINT})
|
</insert>
|
<insert id="insertSelective" parameterType="com.landtool.lanbase.modules.res.entity.Res_ThemeType" >
|
insert into RES_THEMETYPE
|
<trim prefix="(" suffix=")" suffixOverrides="," >
|
<if test="typeid != null" >
|
TYPEID,
|
</if>
|
<if test="title != null" >
|
TITLE,
|
</if>
|
<if test="content != null" >
|
CONTENT,
|
</if>
|
<if test="adduserid != null" >
|
ADDUSERID,
|
</if>
|
<if test="addtime != null" >
|
ADDTIME,
|
</if>
|
<if test="orderindex != null" >
|
ORDERINDEX,
|
</if>
|
<if test="themes != null" >
|
THEMES,
|
</if>
|
<if test="isdefault != null" >
|
ISDEFAULT,
|
</if>
|
</trim>
|
<trim prefix="values (" suffix=")" suffixOverrides="," >
|
<if test="typeid != null" >
|
#{typeid,jdbcType=INTEGER},
|
</if>
|
<if test="title != null" >
|
#{title,jdbcType=VARCHAR},
|
</if>
|
<if test="content != null" >
|
#{content,jdbcType=VARCHAR},
|
</if>
|
<if test="adduserid != null" >
|
#{adduserid,jdbcType=INTEGER},
|
</if>
|
<if test="addtime != null" >
|
#{addtime,jdbcType=TIMESTAMP},
|
</if>
|
<if test="orderindex != null" >
|
#{orderindex,jdbcType=INTEGER},
|
</if>
|
<if test="themes != null" >
|
#{themes,jdbcType=VARCHAR},
|
</if>
|
<if test="isdefault != null" >
|
#{isdefault,jdbcType=TINYINT},
|
</if>
|
</trim>
|
</insert>
|
<update id="updateByPrimaryKeySelective" parameterType="com.landtool.lanbase.modules.res.entity.Res_ThemeType" >
|
update RES_THEMETYPE
|
<set >
|
<if test="title != null" >
|
TITLE = #{title,jdbcType=VARCHAR},
|
</if>
|
<if test="content != null" >
|
CONTENT = #{content,jdbcType=VARCHAR},
|
</if>
|
<if test="adduserid != null" >
|
ADDUSERID = #{adduserid,jdbcType=INTEGER},
|
</if>
|
<if test="addtime != null" >
|
ADDTIME = #{addtime,jdbcType=TIMESTAMP},
|
</if>
|
<if test="orderindex != null" >
|
ORDERINDEX = #{orderindex,jdbcType=INTEGER},
|
</if>
|
<if test="themes != null" >
|
THEMES = #{themes,jdbcType=VARCHAR},
|
</if>
|
<if test="isdefault != null" >
|
ISDEFAULT = #{isdefault,jdbcType=TINYINT},
|
</if>
|
</set>
|
where TYPEID = #{typeid,jdbcType=INTEGER}
|
</update>
|
<update id="updateByPrimaryKey" parameterType="com.landtool.lanbase.modules.res.entity.Res_ThemeType" >
|
update RES_THEMETYPE
|
set TITLE = #{title,jdbcType=VARCHAR},
|
CONTENT = #{content,jdbcType=VARCHAR},
|
ADDUSERID = #{adduserid,jdbcType=INTEGER},
|
ADDTIME = #{addtime,jdbcType=TIMESTAMP},
|
ORDERINDEX = #{orderindex,jdbcType=INTEGER},
|
THEMES = #{themes,jdbcType=VARCHAR},
|
ISDEFAULT = #{isdefault,jdbcType=TINYINT}
|
where TYPEID = #{typeid,jdbcType=INTEGER}
|
</update>
|
</mapper>
|