|
|
@@ -1,301 +1,107 @@
|
|
|
<?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="com.goafanti.common.dao.TTaskLogMapper">
|
|
|
- <resultMap id="BaseResultMap" type="com.goafanti.common.model.TTaskLog">
|
|
|
- <!--
|
|
|
- WARNING - @mbg.generated
|
|
|
- This element is automatically generated by MyBatis Generator, do not modify.
|
|
|
- This element was generated on Tue Dec 04 15:28:04 CST 2018.
|
|
|
- -->
|
|
|
- <id column="id" jdbcType="INTEGER" property="id" />
|
|
|
- <result column="task_id" jdbcType="INTEGER" property="taskId" />
|
|
|
- <result column="task_allocator" jdbcType="VARCHAR" property="taskAllocator" />
|
|
|
- <result column="task_receiver" jdbcType="VARCHAR" property="taskReceiver" />
|
|
|
- <result column="create_time" jdbcType="TIMESTAMP" property="createTime" />
|
|
|
- </resultMap>
|
|
|
- <sql id="Example_Where_Clause">
|
|
|
- <!--
|
|
|
- WARNING - @mbg.generated
|
|
|
- This element is automatically generated by MyBatis Generator, do not modify.
|
|
|
- This element was generated on Tue Dec 04 15:28:04 CST 2018.
|
|
|
- -->
|
|
|
- <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">
|
|
|
- <!--
|
|
|
- WARNING - @mbg.generated
|
|
|
- This element is automatically generated by MyBatis Generator, do not modify.
|
|
|
- This element was generated on Tue Dec 04 15:28:04 CST 2018.
|
|
|
- -->
|
|
|
- <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">
|
|
|
- <!--
|
|
|
- WARNING - @mbg.generated
|
|
|
- This element is automatically generated by MyBatis Generator, do not modify.
|
|
|
- This element was generated on Tue Dec 04 15:28:04 CST 2018.
|
|
|
- -->
|
|
|
- id, task_id, task_allocator, task_receiver, create_time
|
|
|
- </sql>
|
|
|
- <select id="selectByExample" parameterType="com.goafanti.common.model.TTaskLogExample" resultMap="BaseResultMap">
|
|
|
- <!--
|
|
|
- WARNING - @mbg.generated
|
|
|
- This element is automatically generated by MyBatis Generator, do not modify.
|
|
|
- This element was generated on Tue Dec 04 15:28:04 CST 2018.
|
|
|
- -->
|
|
|
- select
|
|
|
- <if test="distinct">
|
|
|
- distinct
|
|
|
- </if>
|
|
|
- <include refid="Base_Column_List" />
|
|
|
- from t_task_log
|
|
|
- <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.Integer" resultMap="BaseResultMap">
|
|
|
- <!--
|
|
|
- WARNING - @mbg.generated
|
|
|
- This element is automatically generated by MyBatis Generator, do not modify.
|
|
|
- This element was generated on Tue Dec 04 15:28:04 CST 2018.
|
|
|
- -->
|
|
|
- select
|
|
|
- <include refid="Base_Column_List" />
|
|
|
- from t_task_log
|
|
|
- where id = #{id,jdbcType=INTEGER}
|
|
|
- </select>
|
|
|
- <delete id="deleteByPrimaryKey" parameterType="java.lang.Integer">
|
|
|
- <!--
|
|
|
- WARNING - @mbg.generated
|
|
|
- This element is automatically generated by MyBatis Generator, do not modify.
|
|
|
- This element was generated on Tue Dec 04 15:28:04 CST 2018.
|
|
|
- -->
|
|
|
- delete from t_task_log
|
|
|
- where id = #{id,jdbcType=INTEGER}
|
|
|
- </delete>
|
|
|
- <delete id="deleteByExample" parameterType="com.goafanti.common.model.TTaskLogExample">
|
|
|
- <!--
|
|
|
- WARNING - @mbg.generated
|
|
|
- This element is automatically generated by MyBatis Generator, do not modify.
|
|
|
- This element was generated on Tue Dec 04 15:28:04 CST 2018.
|
|
|
- -->
|
|
|
- delete from t_task_log
|
|
|
- <if test="_parameter != null">
|
|
|
- <include refid="Example_Where_Clause" />
|
|
|
- </if>
|
|
|
- </delete>
|
|
|
- <insert id="insert" parameterType="com.goafanti.common.model.TTaskLog">
|
|
|
- <!--
|
|
|
- WARNING - @mbg.generated
|
|
|
- This element is automatically generated by MyBatis Generator, do not modify.
|
|
|
- This element was generated on Tue Dec 04 15:28:04 CST 2018.
|
|
|
- -->
|
|
|
- insert into t_task_log (id, task_id, task_allocator,
|
|
|
- task_receiver, create_time)
|
|
|
- values (#{id,jdbcType=INTEGER}, #{taskId,jdbcType=INTEGER}, #{taskAllocator,jdbcType=VARCHAR},
|
|
|
- #{taskReceiver,jdbcType=VARCHAR}, #{createTime,jdbcType=TIMESTAMP})
|
|
|
- </insert>
|
|
|
- <insert id="insertSelective" parameterType="com.goafanti.common.model.TTaskLog">
|
|
|
- <!--
|
|
|
- WARNING - @mbg.generated
|
|
|
- This element is automatically generated by MyBatis Generator, do not modify.
|
|
|
- This element was generated on Tue Dec 04 15:28:04 CST 2018.
|
|
|
- -->
|
|
|
- insert into t_task_log
|
|
|
- <trim prefix="(" suffix=")" suffixOverrides=",">
|
|
|
- <if test="id != null">
|
|
|
- id,
|
|
|
- </if>
|
|
|
- <if test="taskId != null">
|
|
|
- task_id,
|
|
|
- </if>
|
|
|
- <if test="taskAllocator != null">
|
|
|
- task_allocator,
|
|
|
- </if>
|
|
|
- <if test="taskReceiver != null">
|
|
|
- task_receiver,
|
|
|
- </if>
|
|
|
- <if test="createTime != null">
|
|
|
- create_time,
|
|
|
- </if>
|
|
|
- </trim>
|
|
|
- <trim prefix="values (" suffix=")" suffixOverrides=",">
|
|
|
- <if test="id != null">
|
|
|
- #{id,jdbcType=INTEGER},
|
|
|
- </if>
|
|
|
- <if test="taskId != null">
|
|
|
- #{taskId,jdbcType=INTEGER},
|
|
|
- </if>
|
|
|
- <if test="taskAllocator != null">
|
|
|
- #{taskAllocator,jdbcType=VARCHAR},
|
|
|
- </if>
|
|
|
- <if test="taskReceiver != null">
|
|
|
- #{taskReceiver,jdbcType=VARCHAR},
|
|
|
- </if>
|
|
|
- <if test="createTime != null">
|
|
|
- #{createTime,jdbcType=TIMESTAMP},
|
|
|
- </if>
|
|
|
- </trim>
|
|
|
- </insert>
|
|
|
- <select id="countByExample" parameterType="com.goafanti.common.model.TTaskLogExample" resultType="java.lang.Long">
|
|
|
- <!--
|
|
|
- WARNING - @mbg.generated
|
|
|
- This element is automatically generated by MyBatis Generator, do not modify.
|
|
|
- This element was generated on Tue Dec 04 15:28:04 CST 2018.
|
|
|
- -->
|
|
|
- select count(*) from t_task_log
|
|
|
- <if test="_parameter != null">
|
|
|
- <include refid="Example_Where_Clause" />
|
|
|
- </if>
|
|
|
- </select>
|
|
|
|
|
|
- <update id="updateByExampleSelective" parameterType="map">
|
|
|
- <!--
|
|
|
- WARNING - @mbg.generated
|
|
|
- This element is automatically generated by MyBatis Generator, do not modify.
|
|
|
- This element was generated on Tue Dec 04 15:28:04 CST 2018.
|
|
|
- -->
|
|
|
- update t_task_log
|
|
|
- <set>
|
|
|
- <if test="record.id != null">
|
|
|
- id = #{record.id,jdbcType=INTEGER},
|
|
|
- </if>
|
|
|
- <if test="record.taskId != null">
|
|
|
- task_id = #{record.taskId,jdbcType=INTEGER},
|
|
|
- </if>
|
|
|
- <if test="record.taskAllocator != null">
|
|
|
- task_allocator = #{record.taskAllocator,jdbcType=VARCHAR},
|
|
|
- </if>
|
|
|
- <if test="record.taskReceiver != null">
|
|
|
- task_receiver = #{record.taskReceiver,jdbcType=VARCHAR},
|
|
|
- </if>
|
|
|
- <if test="record.createTime != null">
|
|
|
- create_time = #{record.createTime,jdbcType=TIMESTAMP},
|
|
|
- </if>
|
|
|
- </set>
|
|
|
- <if test="_parameter != null">
|
|
|
- <include refid="Update_By_Example_Where_Clause" />
|
|
|
- </if>
|
|
|
- </update>
|
|
|
- <update id="updateByExample" parameterType="map">
|
|
|
- <!--
|
|
|
- WARNING - @mbg.generated
|
|
|
- This element is automatically generated by MyBatis Generator, do not modify.
|
|
|
- This element was generated on Tue Dec 04 15:28:04 CST 2018.
|
|
|
- -->
|
|
|
- update t_task_log
|
|
|
- set id = #{record.id,jdbcType=INTEGER},
|
|
|
- task_id = #{record.taskId,jdbcType=INTEGER},
|
|
|
- task_allocator = #{record.taskAllocator,jdbcType=VARCHAR},
|
|
|
- task_receiver = #{record.taskReceiver,jdbcType=VARCHAR},
|
|
|
- create_time = #{record.createTime,jdbcType=TIMESTAMP}
|
|
|
- <if test="_parameter != null">
|
|
|
- <include refid="Update_By_Example_Where_Clause" />
|
|
|
- </if>
|
|
|
- </update>
|
|
|
- <update id="updateByPrimaryKeySelective" parameterType="com.goafanti.common.model.TTaskLog">
|
|
|
- <!--
|
|
|
- WARNING - @mbg.generated
|
|
|
- This element is automatically generated by MyBatis Generator, do not modify.
|
|
|
- This element was generated on Tue Dec 04 15:28:04 CST 2018.
|
|
|
- -->
|
|
|
- update t_task_log
|
|
|
- <set>
|
|
|
- <if test="taskId != null">
|
|
|
- task_id = #{taskId,jdbcType=INTEGER},
|
|
|
- </if>
|
|
|
- <if test="taskAllocator != null">
|
|
|
- task_allocator = #{taskAllocator,jdbcType=VARCHAR},
|
|
|
- </if>
|
|
|
- <if test="taskReceiver != null">
|
|
|
- task_receiver = #{taskReceiver,jdbcType=VARCHAR},
|
|
|
- </if>
|
|
|
- <if test="createTime != null">
|
|
|
- create_time = #{createTime,jdbcType=TIMESTAMP},
|
|
|
- </if>
|
|
|
- </set>
|
|
|
- where id = #{id,jdbcType=INTEGER}
|
|
|
- </update>
|
|
|
- <update id="updateByPrimaryKey" parameterType="com.goafanti.common.model.TTaskLog">
|
|
|
- <!--
|
|
|
- WARNING - @mbg.generated
|
|
|
- This element is automatically generated by MyBatis Generator, do not modify.
|
|
|
- This element was generated on Tue Dec 04 15:28:04 CST 2018.
|
|
|
- -->
|
|
|
- update t_task_log
|
|
|
- set task_id = #{taskId,jdbcType=INTEGER},
|
|
|
- task_allocator = #{taskAllocator,jdbcType=VARCHAR},
|
|
|
- task_receiver = #{taskReceiver,jdbcType=VARCHAR},
|
|
|
- create_time = #{createTime,jdbcType=TIMESTAMP}
|
|
|
- where id = #{id,jdbcType=INTEGER}
|
|
|
- </update>
|
|
|
- <update id="updateDimissionTransfer" parameterType="java.lang.String">
|
|
|
- update t_task_log set
|
|
|
- task_receiver = #{transferId,jdbcType=VARCHAR}
|
|
|
- where task_receiver = #{aid,jdbcType=VARCHAR}
|
|
|
- </update>
|
|
|
+ <resultMap id="BaseResultMap" type="com.goafanti.common.model.TTaskLog">
|
|
|
+ <id property="id" column="id" jdbcType="INTEGER"/>
|
|
|
+ <result property="taskId" column="task_id" jdbcType="INTEGER"/>
|
|
|
+ <result property="taskAllocator" column="task_allocator" jdbcType="VARCHAR"/>
|
|
|
+ <result property="taskReceiver" column="task_receiver" jdbcType="VARCHAR"/>
|
|
|
+ <result property="createTime" column="create_time" jdbcType="TIMESTAMP"/>
|
|
|
+ <result property="status" column="status" jdbcType="INTEGER"/>
|
|
|
+ </resultMap>
|
|
|
|
|
|
+ <sql id="Base_Column_List">
|
|
|
+ id,task_id,task_allocator,
|
|
|
+ task_receiver,create_time,status
|
|
|
+ </sql>
|
|
|
|
|
|
- <select id="selectByTid" resultType="com.goafanti.order.bo.OutTTaskLog">
|
|
|
- select a.id,b.name taskAllocatorName,c.name taskReceiverName,a.create_time createTime
|
|
|
- from t_task_log a
|
|
|
- left join admin b on a.task_allocator =b.id
|
|
|
- left join admin c on a.task_receiver =c.id
|
|
|
- where task_id = #{id}
|
|
|
- </select>
|
|
|
-</mapper>
|
|
|
+ <select id="selectByPrimaryKey" parameterType="java.lang.Integer" resultMap="BaseResultMap">
|
|
|
+ select
|
|
|
+ <include refid="Base_Column_List" />
|
|
|
+ from t_task_log
|
|
|
+ where id = #{id,jdbcType=INTEGER}
|
|
|
+ </select>
|
|
|
+
|
|
|
+ <delete id="deleteByPrimaryKey" parameterType="java.lang.Integer">
|
|
|
+ delete from t_task_log
|
|
|
+ where id = #{id,jdbcType=INTEGER}
|
|
|
+ </delete>
|
|
|
+ <insert id="insert" keyColumn="id" keyProperty="id" parameterType="com.goafanti.common.model.TTaskLog" useGeneratedKeys="true">
|
|
|
+ insert into t_task_log
|
|
|
+ ( id,task_id,task_allocator
|
|
|
+ ,task_receiver,create_time,status
|
|
|
+ )
|
|
|
+ values (#{id,jdbcType=INTEGER},#{taskId,jdbcType=INTEGER},#{taskAllocator,jdbcType=VARCHAR}
|
|
|
+ ,#{taskReceiver,jdbcType=VARCHAR},#{createTime,jdbcType=TIMESTAMP},#{status,jdbcType=INTEGER}
|
|
|
+ )
|
|
|
+ </insert>
|
|
|
+ <insert id="insertSelective" keyColumn="id" keyProperty="id" parameterType="com.goafanti.common.model.TTaskLog" useGeneratedKeys="true">
|
|
|
+ insert into t_task_log
|
|
|
+ <trim prefix="(" suffix=")" suffixOverrides=",">
|
|
|
+ <if test="id != null">id,</if>
|
|
|
+ <if test="taskId != null">task_id,</if>
|
|
|
+ <if test="taskAllocator != null">task_allocator,</if>
|
|
|
+ <if test="taskReceiver != null">task_receiver,</if>
|
|
|
+ <if test="createTime != null">create_time,</if>
|
|
|
+ <if test="status != null">status,</if>
|
|
|
+ </trim>
|
|
|
+ <trim prefix="values (" suffix=")" suffixOverrides=",">
|
|
|
+ <if test="id != null">#{id,jdbcType=INTEGER},</if>
|
|
|
+ <if test="taskId != null">#{taskId,jdbcType=INTEGER},</if>
|
|
|
+ <if test="taskAllocator != null">#{taskAllocator,jdbcType=VARCHAR},</if>
|
|
|
+ <if test="taskReceiver != null">#{taskReceiver,jdbcType=VARCHAR},</if>
|
|
|
+ <if test="createTime != null">#{createTime,jdbcType=TIMESTAMP},</if>
|
|
|
+ <if test="status != null">#{status,jdbcType=INTEGER},</if>
|
|
|
+ </trim>
|
|
|
+ </insert>
|
|
|
+ <update id="updateByPrimaryKeySelective" parameterType="com.goafanti.common.model.TTaskLog">
|
|
|
+ update t_task_log
|
|
|
+ <set>
|
|
|
+ <if test="taskId != null">
|
|
|
+ task_id = #{taskId,jdbcType=INTEGER},
|
|
|
+ </if>
|
|
|
+ <if test="taskAllocator != null">
|
|
|
+ task_allocator = #{taskAllocator,jdbcType=VARCHAR},
|
|
|
+ </if>
|
|
|
+ <if test="taskReceiver != null">
|
|
|
+ task_receiver = #{taskReceiver,jdbcType=VARCHAR},
|
|
|
+ </if>
|
|
|
+ <if test="createTime != null">
|
|
|
+ create_time = #{createTime,jdbcType=TIMESTAMP},
|
|
|
+ </if>
|
|
|
+ <if test="status != null">
|
|
|
+ status = #{status,jdbcType=INTEGER},
|
|
|
+ </if>
|
|
|
+ </set>
|
|
|
+ where id = #{id,jdbcType=INTEGER}
|
|
|
+ </update>
|
|
|
+ <update id="updateByPrimaryKey" parameterType="com.goafanti.common.model.TTaskLog">
|
|
|
+ update t_task_log
|
|
|
+ set
|
|
|
+ task_id = #{taskId,jdbcType=INTEGER},
|
|
|
+ task_allocator = #{taskAllocator,jdbcType=VARCHAR},
|
|
|
+ task_receiver = #{taskReceiver,jdbcType=VARCHAR},
|
|
|
+ create_time = #{createTime,jdbcType=TIMESTAMP},
|
|
|
+ status = #{status,jdbcType=INTEGER}
|
|
|
+ where id = #{id,jdbcType=INTEGER}
|
|
|
+ </update>
|
|
|
+
|
|
|
+
|
|
|
+ <update id="updateDimissionTransfer" parameterType="java.lang.String">
|
|
|
+ update t_task_log set
|
|
|
+ task_receiver = #{transferId,jdbcType=VARCHAR}
|
|
|
+ where task_receiver = #{aid,jdbcType=VARCHAR}
|
|
|
+ </update>
|
|
|
+
|
|
|
+
|
|
|
+ <select id="selectByTid" resultType="com.goafanti.order.bo.OutTTaskLog">
|
|
|
+ select a.id,b.name taskAllocatorName,c.name taskReceiverName,a.create_time createTime
|
|
|
+ from t_task_log a
|
|
|
+ left join admin b on a.task_allocator =b.id
|
|
|
+ left join admin c on a.task_receiver =c.id
|
|
|
+ where task_id = #{id}
|
|
|
+ </select>
|
|
|
+</mapper>
|