You can not select more than 25 topics
Topics must start with a letter or number, can include dashes ('-') and can be up to 35 characters long.
401 lines
15 KiB
401 lines
15 KiB
<?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.ccsens.tall.persist.mapper.SysProjectMapper">
|
|
<resultMap id="BaseResultMap" type="com.ccsens.tall.bean.po.SysProject">
|
|
<id column="id" jdbcType="BIGINT" property="id" />
|
|
<result column="creator_id" jdbcType="BIGINT" property="creatorId" />
|
|
<result column="parent_task_id" jdbcType="BIGINT" property="parentTaskId" />
|
|
<result column="scene_id" jdbcType="BIGINT" property="sceneId" />
|
|
<result column="name" jdbcType="VARCHAR" property="name" />
|
|
<result column="description" jdbcType="VARCHAR" property="description" />
|
|
<result column="begin_time" jdbcType="BIGINT" property="beginTime" />
|
|
<result column="end_time" jdbcType="BIGINT" property="endTime" />
|
|
<result column="address" jdbcType="VARCHAR" property="address" />
|
|
<result column="published" jdbcType="TINYINT" property="published" />
|
|
<result column="template" jdbcType="TINYINT" property="template" />
|
|
<result column="created_at" jdbcType="TIMESTAMP" property="createdAt" />
|
|
<result column="updated_at" jdbcType="TIMESTAMP" property="updatedAt" />
|
|
<result column="rec_status" jdbcType="TINYINT" property="recStatus" />
|
|
<result column="parent_id" jdbcType="BIGINT" property="parentId" />
|
|
<result column="home_page_show" jdbcType="TINYINT" property="homePageShow" />
|
|
<result column="highlight" jdbcType="TINYINT" property="highlight" />
|
|
</resultMap>
|
|
<sql id="Example_Where_Clause">
|
|
<where>
|
|
<foreach collection="oredCriteria" item="criteria" separator="or">
|
|
<if test="criteria.valid">
|
|
<trim prefix="(" prefixOverrides="and" suffix=")">
|
|
<foreach collection="criteria.criteria" item="criterion">
|
|
<choose>
|
|
<when test="criterion.noValue">
|
|
and ${criterion.condition}
|
|
</when>
|
|
<when test="criterion.singleValue">
|
|
and ${criterion.condition} #{criterion.value}
|
|
</when>
|
|
<when test="criterion.betweenValue">
|
|
and ${criterion.condition} #{criterion.value} and #{criterion.secondValue}
|
|
</when>
|
|
<when test="criterion.listValue">
|
|
and ${criterion.condition}
|
|
<foreach close=")" collection="criterion.value" item="listItem" open="(" separator=",">
|
|
#{listItem}
|
|
</foreach>
|
|
</when>
|
|
</choose>
|
|
</foreach>
|
|
</trim>
|
|
</if>
|
|
</foreach>
|
|
</where>
|
|
</sql>
|
|
<sql id="Update_By_Example_Where_Clause">
|
|
<where>
|
|
<foreach collection="example.oredCriteria" item="criteria" separator="or">
|
|
<if test="criteria.valid">
|
|
<trim prefix="(" prefixOverrides="and" suffix=")">
|
|
<foreach collection="criteria.criteria" item="criterion">
|
|
<choose>
|
|
<when test="criterion.noValue">
|
|
and ${criterion.condition}
|
|
</when>
|
|
<when test="criterion.singleValue">
|
|
and ${criterion.condition} #{criterion.value}
|
|
</when>
|
|
<when test="criterion.betweenValue">
|
|
and ${criterion.condition} #{criterion.value} and #{criterion.secondValue}
|
|
</when>
|
|
<when test="criterion.listValue">
|
|
and ${criterion.condition}
|
|
<foreach close=")" collection="criterion.value" item="listItem" open="(" separator=",">
|
|
#{listItem}
|
|
</foreach>
|
|
</when>
|
|
</choose>
|
|
</foreach>
|
|
</trim>
|
|
</if>
|
|
</foreach>
|
|
</where>
|
|
</sql>
|
|
<sql id="Base_Column_List">
|
|
id, creator_id, parent_task_id, scene_id, name, description, begin_time, end_time,
|
|
address, published, template, created_at, updated_at, rec_status, parent_id, home_page_show,
|
|
highlight
|
|
</sql>
|
|
<select id="selectByExample" parameterType="com.ccsens.tall.bean.po.SysProjectExample" resultMap="BaseResultMap">
|
|
select
|
|
<if test="distinct">
|
|
distinct
|
|
</if>
|
|
<include refid="Base_Column_List" />
|
|
from t_sys_project
|
|
<if test="_parameter != null">
|
|
<include refid="Example_Where_Clause" />
|
|
</if>
|
|
<if test="orderByClause != null">
|
|
order by ${orderByClause}
|
|
</if>
|
|
</select>
|
|
<select id="selectByPrimaryKey" parameterType="java.lang.Long" resultMap="BaseResultMap">
|
|
select
|
|
<include refid="Base_Column_List" />
|
|
from t_sys_project
|
|
where id = #{id,jdbcType=BIGINT}
|
|
</select>
|
|
<delete id="deleteByPrimaryKey" parameterType="java.lang.Long">
|
|
delete from t_sys_project
|
|
where id = #{id,jdbcType=BIGINT}
|
|
</delete>
|
|
<delete id="deleteByExample" parameterType="com.ccsens.tall.bean.po.SysProjectExample">
|
|
delete from t_sys_project
|
|
<if test="_parameter != null">
|
|
<include refid="Example_Where_Clause" />
|
|
</if>
|
|
</delete>
|
|
<insert id="insert" parameterType="com.ccsens.tall.bean.po.SysProject">
|
|
insert into t_sys_project (id, creator_id, parent_task_id,
|
|
scene_id, name, description,
|
|
begin_time, end_time, address,
|
|
published, template, created_at,
|
|
updated_at, rec_status, parent_id,
|
|
home_page_show, highlight)
|
|
values (#{id,jdbcType=BIGINT}, #{creatorId,jdbcType=BIGINT}, #{parentTaskId,jdbcType=BIGINT},
|
|
#{sceneId,jdbcType=BIGINT}, #{name,jdbcType=VARCHAR}, #{description,jdbcType=VARCHAR},
|
|
#{beginTime,jdbcType=BIGINT}, #{endTime,jdbcType=BIGINT}, #{address,jdbcType=VARCHAR},
|
|
#{published,jdbcType=TINYINT}, #{template,jdbcType=TINYINT}, #{createdAt,jdbcType=TIMESTAMP},
|
|
#{updatedAt,jdbcType=TIMESTAMP}, #{recStatus,jdbcType=TINYINT}, #{parentId,jdbcType=BIGINT},
|
|
#{homePageShow,jdbcType=TINYINT}, #{highlight,jdbcType=TINYINT})
|
|
</insert>
|
|
<insert id="insertSelective" parameterType="com.ccsens.tall.bean.po.SysProject">
|
|
insert into t_sys_project
|
|
<trim prefix="(" suffix=")" suffixOverrides=",">
|
|
<if test="id != null">
|
|
id,
|
|
</if>
|
|
<if test="creatorId != null">
|
|
creator_id,
|
|
</if>
|
|
<if test="parentTaskId != null">
|
|
parent_task_id,
|
|
</if>
|
|
<if test="sceneId != null">
|
|
scene_id,
|
|
</if>
|
|
<if test="name != null">
|
|
name,
|
|
</if>
|
|
<if test="description != null">
|
|
description,
|
|
</if>
|
|
<if test="beginTime != null">
|
|
begin_time,
|
|
</if>
|
|
<if test="endTime != null">
|
|
end_time,
|
|
</if>
|
|
<if test="address != null">
|
|
address,
|
|
</if>
|
|
<if test="published != null">
|
|
published,
|
|
</if>
|
|
<if test="template != null">
|
|
template,
|
|
</if>
|
|
<if test="createdAt != null">
|
|
created_at,
|
|
</if>
|
|
<if test="updatedAt != null">
|
|
updated_at,
|
|
</if>
|
|
<if test="recStatus != null">
|
|
rec_status,
|
|
</if>
|
|
<if test="parentId != null">
|
|
parent_id,
|
|
</if>
|
|
<if test="homePageShow != null">
|
|
home_page_show,
|
|
</if>
|
|
<if test="highlight != null">
|
|
highlight,
|
|
</if>
|
|
</trim>
|
|
<trim prefix="values (" suffix=")" suffixOverrides=",">
|
|
<if test="id != null">
|
|
#{id,jdbcType=BIGINT},
|
|
</if>
|
|
<if test="creatorId != null">
|
|
#{creatorId,jdbcType=BIGINT},
|
|
</if>
|
|
<if test="parentTaskId != null">
|
|
#{parentTaskId,jdbcType=BIGINT},
|
|
</if>
|
|
<if test="sceneId != null">
|
|
#{sceneId,jdbcType=BIGINT},
|
|
</if>
|
|
<if test="name != null">
|
|
#{name,jdbcType=VARCHAR},
|
|
</if>
|
|
<if test="description != null">
|
|
#{description,jdbcType=VARCHAR},
|
|
</if>
|
|
<if test="beginTime != null">
|
|
#{beginTime,jdbcType=BIGINT},
|
|
</if>
|
|
<if test="endTime != null">
|
|
#{endTime,jdbcType=BIGINT},
|
|
</if>
|
|
<if test="address != null">
|
|
#{address,jdbcType=VARCHAR},
|
|
</if>
|
|
<if test="published != null">
|
|
#{published,jdbcType=TINYINT},
|
|
</if>
|
|
<if test="template != null">
|
|
#{template,jdbcType=TINYINT},
|
|
</if>
|
|
<if test="createdAt != null">
|
|
#{createdAt,jdbcType=TIMESTAMP},
|
|
</if>
|
|
<if test="updatedAt != null">
|
|
#{updatedAt,jdbcType=TIMESTAMP},
|
|
</if>
|
|
<if test="recStatus != null">
|
|
#{recStatus,jdbcType=TINYINT},
|
|
</if>
|
|
<if test="parentId != null">
|
|
#{parentId,jdbcType=BIGINT},
|
|
</if>
|
|
<if test="homePageShow != null">
|
|
#{homePageShow,jdbcType=TINYINT},
|
|
</if>
|
|
<if test="highlight != null">
|
|
#{highlight,jdbcType=TINYINT},
|
|
</if>
|
|
</trim>
|
|
</insert>
|
|
<select id="countByExample" parameterType="com.ccsens.tall.bean.po.SysProjectExample" resultType="java.lang.Long">
|
|
select count(*) from t_sys_project
|
|
<if test="_parameter != null">
|
|
<include refid="Example_Where_Clause" />
|
|
</if>
|
|
</select>
|
|
<update id="updateByExampleSelective" parameterType="map">
|
|
update t_sys_project
|
|
<set>
|
|
<if test="record.id != null">
|
|
id = #{record.id,jdbcType=BIGINT},
|
|
</if>
|
|
<if test="record.creatorId != null">
|
|
creator_id = #{record.creatorId,jdbcType=BIGINT},
|
|
</if>
|
|
<if test="record.parentTaskId != null">
|
|
parent_task_id = #{record.parentTaskId,jdbcType=BIGINT},
|
|
</if>
|
|
<if test="record.sceneId != null">
|
|
scene_id = #{record.sceneId,jdbcType=BIGINT},
|
|
</if>
|
|
<if test="record.name != null">
|
|
name = #{record.name,jdbcType=VARCHAR},
|
|
</if>
|
|
<if test="record.description != null">
|
|
description = #{record.description,jdbcType=VARCHAR},
|
|
</if>
|
|
<if test="record.beginTime != null">
|
|
begin_time = #{record.beginTime,jdbcType=BIGINT},
|
|
</if>
|
|
<if test="record.endTime != null">
|
|
end_time = #{record.endTime,jdbcType=BIGINT},
|
|
</if>
|
|
<if test="record.address != null">
|
|
address = #{record.address,jdbcType=VARCHAR},
|
|
</if>
|
|
<if test="record.published != null">
|
|
published = #{record.published,jdbcType=TINYINT},
|
|
</if>
|
|
<if test="record.template != null">
|
|
template = #{record.template,jdbcType=TINYINT},
|
|
</if>
|
|
<if test="record.createdAt != null">
|
|
created_at = #{record.createdAt,jdbcType=TIMESTAMP},
|
|
</if>
|
|
<if test="record.updatedAt != null">
|
|
updated_at = #{record.updatedAt,jdbcType=TIMESTAMP},
|
|
</if>
|
|
<if test="record.recStatus != null">
|
|
rec_status = #{record.recStatus,jdbcType=TINYINT},
|
|
</if>
|
|
<if test="record.parentId != null">
|
|
parent_id = #{record.parentId,jdbcType=BIGINT},
|
|
</if>
|
|
<if test="record.homePageShow != null">
|
|
home_page_show = #{record.homePageShow,jdbcType=TINYINT},
|
|
</if>
|
|
<if test="record.highlight != null">
|
|
highlight = #{record.highlight,jdbcType=TINYINT},
|
|
</if>
|
|
</set>
|
|
<if test="_parameter != null">
|
|
<include refid="Update_By_Example_Where_Clause" />
|
|
</if>
|
|
</update>
|
|
<update id="updateByExample" parameterType="map">
|
|
update t_sys_project
|
|
set id = #{record.id,jdbcType=BIGINT},
|
|
creator_id = #{record.creatorId,jdbcType=BIGINT},
|
|
parent_task_id = #{record.parentTaskId,jdbcType=BIGINT},
|
|
scene_id = #{record.sceneId,jdbcType=BIGINT},
|
|
name = #{record.name,jdbcType=VARCHAR},
|
|
description = #{record.description,jdbcType=VARCHAR},
|
|
begin_time = #{record.beginTime,jdbcType=BIGINT},
|
|
end_time = #{record.endTime,jdbcType=BIGINT},
|
|
address = #{record.address,jdbcType=VARCHAR},
|
|
published = #{record.published,jdbcType=TINYINT},
|
|
template = #{record.template,jdbcType=TINYINT},
|
|
created_at = #{record.createdAt,jdbcType=TIMESTAMP},
|
|
updated_at = #{record.updatedAt,jdbcType=TIMESTAMP},
|
|
rec_status = #{record.recStatus,jdbcType=TINYINT},
|
|
parent_id = #{record.parentId,jdbcType=BIGINT},
|
|
home_page_show = #{record.homePageShow,jdbcType=TINYINT},
|
|
highlight = #{record.highlight,jdbcType=TINYINT}
|
|
<if test="_parameter != null">
|
|
<include refid="Update_By_Example_Where_Clause" />
|
|
</if>
|
|
</update>
|
|
<update id="updateByPrimaryKeySelective" parameterType="com.ccsens.tall.bean.po.SysProject">
|
|
update t_sys_project
|
|
<set>
|
|
<if test="creatorId != null">
|
|
creator_id = #{creatorId,jdbcType=BIGINT},
|
|
</if>
|
|
<if test="parentTaskId != null">
|
|
parent_task_id = #{parentTaskId,jdbcType=BIGINT},
|
|
</if>
|
|
<if test="sceneId != null">
|
|
scene_id = #{sceneId,jdbcType=BIGINT},
|
|
</if>
|
|
<if test="name != null">
|
|
name = #{name,jdbcType=VARCHAR},
|
|
</if>
|
|
<if test="description != null">
|
|
description = #{description,jdbcType=VARCHAR},
|
|
</if>
|
|
<if test="beginTime != null">
|
|
begin_time = #{beginTime,jdbcType=BIGINT},
|
|
</if>
|
|
<if test="endTime != null">
|
|
end_time = #{endTime,jdbcType=BIGINT},
|
|
</if>
|
|
<if test="address != null">
|
|
address = #{address,jdbcType=VARCHAR},
|
|
</if>
|
|
<if test="published != null">
|
|
published = #{published,jdbcType=TINYINT},
|
|
</if>
|
|
<if test="template != null">
|
|
template = #{template,jdbcType=TINYINT},
|
|
</if>
|
|
<if test="createdAt != null">
|
|
created_at = #{createdAt,jdbcType=TIMESTAMP},
|
|
</if>
|
|
<if test="updatedAt != null">
|
|
updated_at = #{updatedAt,jdbcType=TIMESTAMP},
|
|
</if>
|
|
<if test="recStatus != null">
|
|
rec_status = #{recStatus,jdbcType=TINYINT},
|
|
</if>
|
|
<if test="parentId != null">
|
|
parent_id = #{parentId,jdbcType=BIGINT},
|
|
</if>
|
|
<if test="homePageShow != null">
|
|
home_page_show = #{homePageShow,jdbcType=TINYINT},
|
|
</if>
|
|
<if test="highlight != null">
|
|
highlight = #{highlight,jdbcType=TINYINT},
|
|
</if>
|
|
</set>
|
|
where id = #{id,jdbcType=BIGINT}
|
|
</update>
|
|
<update id="updateByPrimaryKey" parameterType="com.ccsens.tall.bean.po.SysProject">
|
|
update t_sys_project
|
|
set creator_id = #{creatorId,jdbcType=BIGINT},
|
|
parent_task_id = #{parentTaskId,jdbcType=BIGINT},
|
|
scene_id = #{sceneId,jdbcType=BIGINT},
|
|
name = #{name,jdbcType=VARCHAR},
|
|
description = #{description,jdbcType=VARCHAR},
|
|
begin_time = #{beginTime,jdbcType=BIGINT},
|
|
end_time = #{endTime,jdbcType=BIGINT},
|
|
address = #{address,jdbcType=VARCHAR},
|
|
published = #{published,jdbcType=TINYINT},
|
|
template = #{template,jdbcType=TINYINT},
|
|
created_at = #{createdAt,jdbcType=TIMESTAMP},
|
|
updated_at = #{updatedAt,jdbcType=TIMESTAMP},
|
|
rec_status = #{recStatus,jdbcType=TINYINT},
|
|
parent_id = #{parentId,jdbcType=BIGINT},
|
|
home_page_show = #{homePageShow,jdbcType=TINYINT},
|
|
highlight = #{highlight,jdbcType=TINYINT}
|
|
where id = #{id,jdbcType=BIGINT}
|
|
</update>
|
|
</mapper>
|