【修改实训发布轨迹表名】

This commit is contained in:
weizhihong 2022-10-28 16:46:11 +08:00
parent e1d431ecb6
commit 8e2d2e6a01
2 changed files with 253 additions and 248 deletions

View File

@ -0,0 +1 @@
rename TABLE trace_training2 to rts_trace_training2;

View File

@ -1,266 +1,270 @@
<?xml version="1.0" encoding="UTF-8"?> <?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"> <!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
<mapper namespace="club.joylink.rtss.dao.TraceTraining2DAO"> <mapper namespace="club.joylink.rtss.dao.TraceTraining2DAO">
<resultMap id="BaseResultMap" type="club.joylink.rtss.entity.training2.TraceTraining2"> <resultMap id="BaseResultMap" type="club.joylink.rtss.entity.training2.TraceTraining2">
<id column="id" jdbcType="BIGINT" property="id" /> <id column="id" jdbcType="BIGINT" property="id"/>
<result column="draft_id" jdbcType="BIGINT" property="draftId" /> <result column="draft_id" jdbcType="BIGINT" property="draftId"/>
<result column="draft_name" jdbcType="VARCHAR" property="draftName" /> <result column="draft_name" jdbcType="VARCHAR" property="draftName"/>
<result column="draft_map_id" jdbcType="BIGINT" property="draftMapId" /> <result column="draft_map_id" jdbcType="BIGINT" property="draftMapId"/>
<result column="pub_id" jdbcType="BIGINT" property="pubId" /> <result column="pub_id" jdbcType="BIGINT" property="pubId"/>
<result column="pub_name" jdbcType="VARCHAR" property="pubName" /> <result column="pub_name" jdbcType="VARCHAR" property="pubName"/>
<result column="trace_creator_id" jdbcType="BIGINT" property="traceCreatorId" /> <result column="trace_creator_id" jdbcType="BIGINT" property="traceCreatorId"/>
<result column="trace_time" jdbcType="TIMESTAMP" property="traceTime" /> <result column="trace_time" jdbcType="TIMESTAMP" property="traceTime"/>
</resultMap> </resultMap>
<sql id="Example_Where_Clause"> <sql id="Example_Where_Clause">
<where> <where>
<foreach collection="oredCriteria" item="criteria" separator="or"> <foreach collection="oredCriteria" item="criteria" separator="or">
<if test="criteria.valid"> <if test="criteria.valid">
<trim prefix="(" prefixOverrides="and" suffix=")"> <trim prefix="(" prefixOverrides="and" suffix=")">
<foreach collection="criteria.criteria" item="criterion"> <foreach collection="criteria.criteria" item="criterion">
<choose> <choose>
<when test="criterion.noValue"> <when test="criterion.noValue">
and ${criterion.condition} and ${criterion.condition}
</when> </when>
<when test="criterion.singleValue"> <when test="criterion.singleValue">
and ${criterion.condition} #{criterion.value} and ${criterion.condition} #{criterion.value}
</when> </when>
<when test="criterion.betweenValue"> <when test="criterion.betweenValue">
and ${criterion.condition} #{criterion.value} and #{criterion.secondValue} and ${criterion.condition} #{criterion.value} and #{criterion.secondValue}
</when> </when>
<when test="criterion.listValue"> <when test="criterion.listValue">
and ${criterion.condition} and ${criterion.condition}
<foreach close=")" collection="criterion.value" item="listItem" open="(" separator=","> <foreach close=")" collection="criterion.value" item="listItem" open="("
#{listItem} separator=",">
</foreach> #{listItem}
</when> </foreach>
</choose> </when>
</choose>
</foreach>
</trim>
</if>
</foreach> </foreach>
</trim> </where>
</if> </sql>
</foreach> <sql id="Update_By_Example_Where_Clause">
</where> <where>
</sql> <foreach collection="example.oredCriteria" item="criteria" separator="or">
<sql id="Update_By_Example_Where_Clause"> <if test="criteria.valid">
<where> <trim prefix="(" prefixOverrides="and" suffix=")">
<foreach collection="example.oredCriteria" item="criteria" separator="or"> <foreach collection="criteria.criteria" item="criterion">
<if test="criteria.valid"> <choose>
<trim prefix="(" prefixOverrides="and" suffix=")"> <when test="criterion.noValue">
<foreach collection="criteria.criteria" item="criterion"> and ${criterion.condition}
<choose> </when>
<when test="criterion.noValue"> <when test="criterion.singleValue">
and ${criterion.condition} and ${criterion.condition} #{criterion.value}
</when> </when>
<when test="criterion.singleValue"> <when test="criterion.betweenValue">
and ${criterion.condition} #{criterion.value} and ${criterion.condition} #{criterion.value} and #{criterion.secondValue}
</when> </when>
<when test="criterion.betweenValue"> <when test="criterion.listValue">
and ${criterion.condition} #{criterion.value} and #{criterion.secondValue} and ${criterion.condition}
</when> <foreach close=")" collection="criterion.value" item="listItem" open="("
<when test="criterion.listValue"> separator=",">
and ${criterion.condition} #{listItem}
<foreach close=")" collection="criterion.value" item="listItem" open="(" separator=","> </foreach>
#{listItem} </when>
</foreach> </choose>
</when> </foreach>
</choose> </trim>
</if>
</foreach> </foreach>
</trim> </where>
</sql>
<sql id="Base_Column_List">
id, draft_id, draft_name, draft_map_id, pub_id, pub_name, trace_creator_id, trace_time
</sql>
<select id="selectByExample" parameterType="club.joylink.rtss.entity.training2.TraceTraining2Example"
resultMap="BaseResultMap">
select
<if test="distinct">
distinct
</if> </if>
</foreach> <include refid="Base_Column_List"/>
</where> from rts_trace_training2
</sql> <if test="_parameter != null">
<sql id="Base_Column_List"> <include refid="Example_Where_Clause"/>
id, draft_id, draft_name, draft_map_id, pub_id, pub_name, trace_creator_id, trace_time </if>
</sql> <if test="orderByClause != null">
<select id="selectByExample" parameterType="club.joylink.rtss.entity.training2.TraceTraining2Example" resultMap="BaseResultMap"> order by ${orderByClause}
select </if>
<if test="distinct"> <if test="limit != null">
distinct <if test="offset != null">
</if> limit ${offset}, ${limit}
<include refid="Base_Column_List" /> </if>
from trace_training2 <if test="offset == null">
<if test="_parameter != null"> limit ${limit}
<include refid="Example_Where_Clause" /> </if>
</if> </if>
<if test="orderByClause != null"> </select>
order by ${orderByClause} <select id="selectByPrimaryKey" parameterType="java.lang.Long" resultMap="BaseResultMap">
</if> select
<if test="limit != null"> <include refid="Base_Column_List"/>
<if test="offset != null"> from rts_trace_training2
limit ${offset}, ${limit} where id = #{id,jdbcType=BIGINT}
</if> </select>
<if test="offset == null"> <delete id="deleteByPrimaryKey" parameterType="java.lang.Long">
limit ${limit} delete from rts_trace_training2
</if> where id = #{id,jdbcType=BIGINT}
</if> </delete>
</select> <delete id="deleteByExample" parameterType="club.joylink.rtss.entity.training2.TraceTraining2Example">
<select id="selectByPrimaryKey" parameterType="java.lang.Long" resultMap="BaseResultMap"> delete from trace_training2
select <if test="_parameter != null">
<include refid="Base_Column_List" /> <include refid="Example_Where_Clause"/>
from trace_training2 </if>
where id = #{id,jdbcType=BIGINT} </delete>
</select> <insert id="insert" parameterType="club.joylink.rtss.entity.training2.TraceTraining2">
<delete id="deleteByPrimaryKey" parameterType="java.lang.Long"> insert into rts_trace_training2 (id, draft_id, draft_name,
delete from trace_training2 draft_map_id, pub_id, pub_name,
where id = #{id,jdbcType=BIGINT} trace_creator_id, trace_time)
</delete> values (#{id,jdbcType=BIGINT}, #{draftId,jdbcType=BIGINT}, #{draftName,jdbcType=VARCHAR},
<delete id="deleteByExample" parameterType="club.joylink.rtss.entity.training2.TraceTraining2Example"> #{draftMapId,jdbcType=BIGINT}, #{pubId,jdbcType=BIGINT}, #{pubName,jdbcType=VARCHAR},
delete from trace_training2 #{traceCreatorId,jdbcType=BIGINT}, #{traceTime,jdbcType=TIMESTAMP})
<if test="_parameter != null"> </insert>
<include refid="Example_Where_Clause" /> <insert id="insertSelective" parameterType="club.joylink.rtss.entity.training2.TraceTraining2">
</if> insert into rts_trace_training2
</delete> <trim prefix="(" suffix=")" suffixOverrides=",">
<insert id="insert" parameterType="club.joylink.rtss.entity.training2.TraceTraining2"> <if test="id != null">
insert into trace_training2 (id, draft_id, draft_name, id,
draft_map_id, pub_id, pub_name, </if>
trace_creator_id, trace_time) <if test="draftId != null">
values (#{id,jdbcType=BIGINT}, #{draftId,jdbcType=BIGINT}, #{draftName,jdbcType=VARCHAR}, draft_id,
#{draftMapId,jdbcType=BIGINT}, #{pubId,jdbcType=BIGINT}, #{pubName,jdbcType=VARCHAR}, </if>
#{traceCreatorId,jdbcType=BIGINT}, #{traceTime,jdbcType=TIMESTAMP}) <if test="draftName != null">
</insert> draft_name,
<insert id="insertSelective" parameterType="club.joylink.rtss.entity.training2.TraceTraining2"> </if>
insert into trace_training2 <if test="draftMapId != null">
<trim prefix="(" suffix=")" suffixOverrides=","> draft_map_id,
<if test="id != null"> </if>
id, <if test="pubId != null">
</if> pub_id,
<if test="draftId != null"> </if>
draft_id, <if test="pubName != null">
</if> pub_name,
<if test="draftName != null"> </if>
draft_name, <if test="traceCreatorId != null">
</if> trace_creator_id,
<if test="draftMapId != null"> </if>
draft_map_id, <if test="traceTime != null">
</if> trace_time,
<if test="pubId != null"> </if>
pub_id, </trim>
</if> <trim prefix="values (" suffix=")" suffixOverrides=",">
<if test="pubName != null"> <if test="id != null">
pub_name, #{id,jdbcType=BIGINT},
</if> </if>
<if test="traceCreatorId != null"> <if test="draftId != null">
trace_creator_id, #{draftId,jdbcType=BIGINT},
</if> </if>
<if test="traceTime != null"> <if test="draftName != null">
trace_time, #{draftName,jdbcType=VARCHAR},
</if> </if>
</trim> <if test="draftMapId != null">
<trim prefix="values (" suffix=")" suffixOverrides=","> #{draftMapId,jdbcType=BIGINT},
<if test="id != null"> </if>
#{id,jdbcType=BIGINT}, <if test="pubId != null">
</if> #{pubId,jdbcType=BIGINT},
<if test="draftId != null"> </if>
#{draftId,jdbcType=BIGINT}, <if test="pubName != null">
</if> #{pubName,jdbcType=VARCHAR},
<if test="draftName != null"> </if>
#{draftName,jdbcType=VARCHAR}, <if test="traceCreatorId != null">
</if> #{traceCreatorId,jdbcType=BIGINT},
<if test="draftMapId != null"> </if>
#{draftMapId,jdbcType=BIGINT}, <if test="traceTime != null">
</if> #{traceTime,jdbcType=TIMESTAMP},
<if test="pubId != null"> </if>
#{pubId,jdbcType=BIGINT}, </trim>
</if> </insert>
<if test="pubName != null"> <select id="countByExample" parameterType="club.joylink.rtss.entity.training2.TraceTraining2Example"
#{pubName,jdbcType=VARCHAR}, resultType="java.lang.Long">
</if> select count(*) from rts_trace_training2
<if test="traceCreatorId != null"> <if test="_parameter != null">
#{traceCreatorId,jdbcType=BIGINT}, <include refid="Example_Where_Clause"/>
</if> </if>
<if test="traceTime != null"> </select>
#{traceTime,jdbcType=TIMESTAMP}, <update id="updateByExampleSelective" parameterType="map">
</if> update rts_trace_training2
</trim> <set>
</insert> <if test="record.id != null">
<select id="countByExample" parameterType="club.joylink.rtss.entity.training2.TraceTraining2Example" resultType="java.lang.Long"> id = #{record.id,jdbcType=BIGINT},
select count(*) from trace_training2 </if>
<if test="_parameter != null"> <if test="record.draftId != null">
<include refid="Example_Where_Clause" /> draft_id = #{record.draftId,jdbcType=BIGINT},
</if> </if>
</select> <if test="record.draftName != null">
<update id="updateByExampleSelective" parameterType="map"> draft_name = #{record.draftName,jdbcType=VARCHAR},
update trace_training2 </if>
<set> <if test="record.draftMapId != null">
<if test="record.id != null"> draft_map_id = #{record.draftMapId,jdbcType=BIGINT},
id = #{record.id,jdbcType=BIGINT}, </if>
</if> <if test="record.pubId != null">
<if test="record.draftId != null"> pub_id = #{record.pubId,jdbcType=BIGINT},
</if>
<if test="record.pubName != null">
pub_name = #{record.pubName,jdbcType=VARCHAR},
</if>
<if test="record.traceCreatorId != null">
trace_creator_id = #{record.traceCreatorId,jdbcType=BIGINT},
</if>
<if test="record.traceTime != null">
trace_time = #{record.traceTime,jdbcType=TIMESTAMP},
</if>
</set>
<if test="_parameter != null">
<include refid="Update_By_Example_Where_Clause"/>
</if>
</update>
<update id="updateByExample" parameterType="map">
update rts_trace_training2
set id = #{record.id,jdbcType=BIGINT},
draft_id = #{record.draftId,jdbcType=BIGINT}, draft_id = #{record.draftId,jdbcType=BIGINT},
</if>
<if test="record.draftName != null">
draft_name = #{record.draftName,jdbcType=VARCHAR}, draft_name = #{record.draftName,jdbcType=VARCHAR},
</if>
<if test="record.draftMapId != null">
draft_map_id = #{record.draftMapId,jdbcType=BIGINT}, draft_map_id = #{record.draftMapId,jdbcType=BIGINT},
</if>
<if test="record.pubId != null">
pub_id = #{record.pubId,jdbcType=BIGINT}, pub_id = #{record.pubId,jdbcType=BIGINT},
</if>
<if test="record.pubName != null">
pub_name = #{record.pubName,jdbcType=VARCHAR}, pub_name = #{record.pubName,jdbcType=VARCHAR},
</if>
<if test="record.traceCreatorId != null">
trace_creator_id = #{record.traceCreatorId,jdbcType=BIGINT}, trace_creator_id = #{record.traceCreatorId,jdbcType=BIGINT},
</if> trace_time = #{record.traceTime,jdbcType=TIMESTAMP}
<if test="record.traceTime != null"> <if test="_parameter != null">
trace_time = #{record.traceTime,jdbcType=TIMESTAMP}, <include refid="Update_By_Example_Where_Clause"/>
</if> </if>
</set> </update>
<if test="_parameter != null"> <update id="updateByPrimaryKeySelective" parameterType="club.joylink.rtss.entity.training2.TraceTraining2">
<include refid="Update_By_Example_Where_Clause" /> update rts_trace_training2
</if> <set>
</update> <if test="draftId != null">
<update id="updateByExample" parameterType="map"> draft_id = #{draftId,jdbcType=BIGINT},
update trace_training2 </if>
set id = #{record.id,jdbcType=BIGINT}, <if test="draftName != null">
draft_id = #{record.draftId,jdbcType=BIGINT}, draft_name = #{draftName,jdbcType=VARCHAR},
draft_name = #{record.draftName,jdbcType=VARCHAR}, </if>
draft_map_id = #{record.draftMapId,jdbcType=BIGINT}, <if test="draftMapId != null">
pub_id = #{record.pubId,jdbcType=BIGINT}, draft_map_id = #{draftMapId,jdbcType=BIGINT},
pub_name = #{record.pubName,jdbcType=VARCHAR}, </if>
trace_creator_id = #{record.traceCreatorId,jdbcType=BIGINT}, <if test="pubId != null">
trace_time = #{record.traceTime,jdbcType=TIMESTAMP} pub_id = #{pubId,jdbcType=BIGINT},
<if test="_parameter != null"> </if>
<include refid="Update_By_Example_Where_Clause" /> <if test="pubName != null">
</if> pub_name = #{pubName,jdbcType=VARCHAR},
</update> </if>
<update id="updateByPrimaryKeySelective" parameterType="club.joylink.rtss.entity.training2.TraceTraining2"> <if test="traceCreatorId != null">
update trace_training2 trace_creator_id = #{traceCreatorId,jdbcType=BIGINT},
<set> </if>
<if test="draftId != null"> <if test="traceTime != null">
draft_id = #{draftId,jdbcType=BIGINT}, trace_time = #{traceTime,jdbcType=TIMESTAMP},
</if> </if>
<if test="draftName != null"> </set>
where id = #{id,jdbcType=BIGINT}
</update>
<update id="updateByPrimaryKey" parameterType="club.joylink.rtss.entity.training2.TraceTraining2">
update rts_trace_training2
set draft_id = #{draftId,jdbcType=BIGINT},
draft_name = #{draftName,jdbcType=VARCHAR}, draft_name = #{draftName,jdbcType=VARCHAR},
</if>
<if test="draftMapId != null">
draft_map_id = #{draftMapId,jdbcType=BIGINT}, draft_map_id = #{draftMapId,jdbcType=BIGINT},
</if>
<if test="pubId != null">
pub_id = #{pubId,jdbcType=BIGINT}, pub_id = #{pubId,jdbcType=BIGINT},
</if>
<if test="pubName != null">
pub_name = #{pubName,jdbcType=VARCHAR}, pub_name = #{pubName,jdbcType=VARCHAR},
</if>
<if test="traceCreatorId != null">
trace_creator_id = #{traceCreatorId,jdbcType=BIGINT}, trace_creator_id = #{traceCreatorId,jdbcType=BIGINT},
</if> trace_time = #{traceTime,jdbcType=TIMESTAMP}
<if test="traceTime != null"> where id = #{id,jdbcType=BIGINT}
trace_time = #{traceTime,jdbcType=TIMESTAMP}, </update>
</if>
</set>
where id = #{id,jdbcType=BIGINT}
</update>
<update id="updateByPrimaryKey" parameterType="club.joylink.rtss.entity.training2.TraceTraining2">
update trace_training2
set draft_id = #{draftId,jdbcType=BIGINT},
draft_name = #{draftName,jdbcType=VARCHAR},
draft_map_id = #{draftMapId,jdbcType=BIGINT},
pub_id = #{pubId,jdbcType=BIGINT},
pub_name = #{pubName,jdbcType=VARCHAR},
trace_creator_id = #{traceCreatorId,jdbcType=BIGINT},
trace_time = #{traceTime,jdbcType=TIMESTAMP}
where id = #{id,jdbcType=BIGINT}
</update>
</mapper> </mapper>