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.
 
 

353 lines
13 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.mt.persist.mapper.CompeteStartOrderMapper">
<resultMap id="BaseResultMap" type="com.ccsens.mt.bean.po.CompeteStartOrder">
<id column="id" jdbcType="BIGINT" property="id" />
<result column="project_id" jdbcType="BIGINT" property="projectId" />
<result column="player_id" jdbcType="BIGINT" property="playerId" />
<result column="team" jdbcType="TINYINT" property="team" />
<result column="compete_order" jdbcType="TINYINT" property="competeOrder" />
<result column="site" jdbcType="TINYINT" property="site" />
<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="task_id" jdbcType="BIGINT" property="taskId" />
<result column="start_time" jdbcType="BIGINT" property="startTime" />
<result column="end_time" jdbcType="BIGINT" property="endTime" />
<result column="remark" jdbcType="VARCHAR" property="remark" />
<result column="waiver" jdbcType="TINYINT" property="waiver" />
</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, project_id, player_id, team, compete_order, site, created_at, updated_at, rec_status,
task_id, start_time, end_time, remark, waiver
</sql>
<select id="selectByExample" parameterType="com.ccsens.mt.bean.po.CompeteStartOrderExample" resultMap="BaseResultMap">
select
<if test="distinct">
distinct
</if>
<include refid="Base_Column_List" />
from t_compete_start_order
<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_compete_start_order
where id = #{id,jdbcType=BIGINT}
</select>
<delete id="deleteByPrimaryKey" parameterType="java.lang.Long">
delete from t_compete_start_order
where id = #{id,jdbcType=BIGINT}
</delete>
<delete id="deleteByExample" parameterType="com.ccsens.mt.bean.po.CompeteStartOrderExample">
delete from t_compete_start_order
<if test="_parameter != null">
<include refid="Example_Where_Clause" />
</if>
</delete>
<insert id="insert" parameterType="com.ccsens.mt.bean.po.CompeteStartOrder">
insert into t_compete_start_order (id, project_id, player_id,
team, compete_order, site,
created_at, updated_at, rec_status,
task_id, start_time, end_time,
remark, waiver)
values (#{id,jdbcType=BIGINT}, #{projectId,jdbcType=BIGINT}, #{playerId,jdbcType=BIGINT},
#{team,jdbcType=TINYINT}, #{competeOrder,jdbcType=TINYINT}, #{site,jdbcType=TINYINT},
#{createdAt,jdbcType=TIMESTAMP}, #{updatedAt,jdbcType=TIMESTAMP}, #{recStatus,jdbcType=TINYINT},
#{taskId,jdbcType=BIGINT}, #{startTime,jdbcType=BIGINT}, #{endTime,jdbcType=BIGINT},
#{remark,jdbcType=VARCHAR}, #{waiver,jdbcType=TINYINT})
</insert>
<insert id="insertSelective" parameterType="com.ccsens.mt.bean.po.CompeteStartOrder">
insert into t_compete_start_order
<trim prefix="(" suffix=")" suffixOverrides=",">
<if test="id != null">
id,
</if>
<if test="projectId != null">
project_id,
</if>
<if test="playerId != null">
player_id,
</if>
<if test="team != null">
team,
</if>
<if test="competeOrder != null">
compete_order,
</if>
<if test="site != null">
site,
</if>
<if test="createdAt != null">
created_at,
</if>
<if test="updatedAt != null">
updated_at,
</if>
<if test="recStatus != null">
rec_status,
</if>
<if test="taskId != null">
task_id,
</if>
<if test="startTime != null">
start_time,
</if>
<if test="endTime != null">
end_time,
</if>
<if test="remark != null">
remark,
</if>
<if test="waiver != null">
waiver,
</if>
</trim>
<trim prefix="values (" suffix=")" suffixOverrides=",">
<if test="id != null">
#{id,jdbcType=BIGINT},
</if>
<if test="projectId != null">
#{projectId,jdbcType=BIGINT},
</if>
<if test="playerId != null">
#{playerId,jdbcType=BIGINT},
</if>
<if test="team != null">
#{team,jdbcType=TINYINT},
</if>
<if test="competeOrder != null">
#{competeOrder,jdbcType=TINYINT},
</if>
<if test="site != null">
#{site,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="taskId != null">
#{taskId,jdbcType=BIGINT},
</if>
<if test="startTime != null">
#{startTime,jdbcType=BIGINT},
</if>
<if test="endTime != null">
#{endTime,jdbcType=BIGINT},
</if>
<if test="remark != null">
#{remark,jdbcType=VARCHAR},
</if>
<if test="waiver != null">
#{waiver,jdbcType=TINYINT},
</if>
</trim>
</insert>
<select id="countByExample" parameterType="com.ccsens.mt.bean.po.CompeteStartOrderExample" resultType="java.lang.Long">
select count(*) from t_compete_start_order
<if test="_parameter != null">
<include refid="Example_Where_Clause" />
</if>
</select>
<update id="updateByExampleSelective" parameterType="map">
update t_compete_start_order
<set>
<if test="record.id != null">
id = #{record.id,jdbcType=BIGINT},
</if>
<if test="record.projectId != null">
project_id = #{record.projectId,jdbcType=BIGINT},
</if>
<if test="record.playerId != null">
player_id = #{record.playerId,jdbcType=BIGINT},
</if>
<if test="record.team != null">
team = #{record.team,jdbcType=TINYINT},
</if>
<if test="record.competeOrder != null">
compete_order = #{record.competeOrder,jdbcType=TINYINT},
</if>
<if test="record.site != null">
site = #{record.site,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.taskId != null">
task_id = #{record.taskId,jdbcType=BIGINT},
</if>
<if test="record.startTime != null">
start_time = #{record.startTime,jdbcType=BIGINT},
</if>
<if test="record.endTime != null">
end_time = #{record.endTime,jdbcType=BIGINT},
</if>
<if test="record.remark != null">
remark = #{record.remark,jdbcType=VARCHAR},
</if>
<if test="record.waiver != null">
waiver = #{record.waiver,jdbcType=TINYINT},
</if>
</set>
<if test="_parameter != null">
<include refid="Update_By_Example_Where_Clause" />
</if>
</update>
<update id="updateByExample" parameterType="map">
update t_compete_start_order
set id = #{record.id,jdbcType=BIGINT},
project_id = #{record.projectId,jdbcType=BIGINT},
player_id = #{record.playerId,jdbcType=BIGINT},
team = #{record.team,jdbcType=TINYINT},
compete_order = #{record.competeOrder,jdbcType=TINYINT},
site = #{record.site,jdbcType=TINYINT},
created_at = #{record.createdAt,jdbcType=TIMESTAMP},
updated_at = #{record.updatedAt,jdbcType=TIMESTAMP},
rec_status = #{record.recStatus,jdbcType=TINYINT},
task_id = #{record.taskId,jdbcType=BIGINT},
start_time = #{record.startTime,jdbcType=BIGINT},
end_time = #{record.endTime,jdbcType=BIGINT},
remark = #{record.remark,jdbcType=VARCHAR},
waiver = #{record.waiver,jdbcType=TINYINT}
<if test="_parameter != null">
<include refid="Update_By_Example_Where_Clause" />
</if>
</update>
<update id="updateByPrimaryKeySelective" parameterType="com.ccsens.mt.bean.po.CompeteStartOrder">
update t_compete_start_order
<set>
<if test="projectId != null">
project_id = #{projectId,jdbcType=BIGINT},
</if>
<if test="playerId != null">
player_id = #{playerId,jdbcType=BIGINT},
</if>
<if test="team != null">
team = #{team,jdbcType=TINYINT},
</if>
<if test="competeOrder != null">
compete_order = #{competeOrder,jdbcType=TINYINT},
</if>
<if test="site != null">
site = #{site,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="taskId != null">
task_id = #{taskId,jdbcType=BIGINT},
</if>
<if test="startTime != null">
start_time = #{startTime,jdbcType=BIGINT},
</if>
<if test="endTime != null">
end_time = #{endTime,jdbcType=BIGINT},
</if>
<if test="remark != null">
remark = #{remark,jdbcType=VARCHAR},
</if>
<if test="waiver != null">
waiver = #{waiver,jdbcType=TINYINT},
</if>
</set>
where id = #{id,jdbcType=BIGINT}
</update>
<update id="updateByPrimaryKey" parameterType="com.ccsens.mt.bean.po.CompeteStartOrder">
update t_compete_start_order
set project_id = #{projectId,jdbcType=BIGINT},
player_id = #{playerId,jdbcType=BIGINT},
team = #{team,jdbcType=TINYINT},
compete_order = #{competeOrder,jdbcType=TINYINT},
site = #{site,jdbcType=TINYINT},
created_at = #{createdAt,jdbcType=TIMESTAMP},
updated_at = #{updatedAt,jdbcType=TIMESTAMP},
rec_status = #{recStatus,jdbcType=TINYINT},
task_id = #{taskId,jdbcType=BIGINT},
start_time = #{startTime,jdbcType=BIGINT},
end_time = #{endTime,jdbcType=BIGINT},
remark = #{remark,jdbcType=VARCHAR},
waiver = #{waiver,jdbcType=TINYINT}
where id = #{id,jdbcType=BIGINT}
</update>
</mapper>