| 123456789101112131415161718192021222324252627282930313233343536373839404142434445464748495051525354555657585960616263646566676869707172737475767778798081828384858687888990919293949596979899100101102103104105106107108109110111112113114115116117118119120121122123124125126127128129130131132133134135136137138139140141142143144145146147148149150151152153154155156157158159160161162163164165166167168169170171172173174175176177178179180181182183184185186187188189190191192193194195196197198199200201202203204205206207208209210211212213214215216217218219220221222223224225226227228229230231232233234235236237238239240241242243244245246247248249250251252253254255256257258259260261262263264265266267268269270271272273274275276277278279280281282283284285286287288289290291292293294295296297298299300301302303304305306307308309310311312313314315316317318319320321322323324325326327328329330331332333334335336337338339340341342343344345346347348349350351352353354355356357358359360361362363364365366367368369370371372373374375376377378379380381382383384385386387388389390391392393394395396397398399400401402403404405406407408409410411412413414415416417418419420421422423424425426427428429430431432433434435436437438439440441442443444445446447448449450451452453454455456457458459460461462463464465466467468469470471472473474475476477478479480481482483484485486487488489490491492493494495496497498499500501502503504505506507508509510511512513514515516517518519520521522523524525526527528529530531532533534535536537538539540541542543544545546547548549550551552553554555556557558559560561562563564565566567568569570571572573574575576577578579580581582583584585586587588589590591592593594595596597598599600601602603604605606607608609610611612613614615616617618619620621622623624625626627628629630631632633634635636637638639640641642643644645646647648649650651652653654655656657658659660661662663664665666667668669670671672673674675676677678679680681682683684685686687688689690691692693694695696697698699700701702703704705706707708709710711712713714715716717718719720721722723724725726727728729730731732733734735736737738739740741742743744745746747748749750751752753754755756757758759760761762763764765766767768769770771772773774775776777778779780781782783784785786787788789790791792793794795796797798799800801802803804805806807808809810811812813814815816817818819820821822823824825826827828829830831832833834835836837838839840841842843844845846847848849850851852853854855856857858859860861862863864865866867868869870871872873874875876877878879880881882883884885886887888889890891892893894895896897898899 |
- <?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.goafanti.common.dao.TOrderTaskMapper">
- <resultMap id="BaseResultMap" type="com.goafanti.common.model.TOrderTask">
- <!--
- WARNING - @mbg.generated
- This element is automatically generated by MyBatis Generator, do not modify.
- This element was generated on Mon Nov 19 11:03:38 CST 2018.
- -->
- <id column="id" jdbcType="INTEGER" property="id" />
- <result column="order_no" jdbcType="VARCHAR" property="orderNo" />
- <result column="super_id" jdbcType="VARCHAR" property="superId" />
- <result column="commodity_id" jdbcType="VARCHAR" property="commodityId" />
- <result column="commodity_name" jdbcType="VARCHAR" property="commodityName" />
- <result column="commodity_quantity" jdbcType="INTEGER" property="commodityQuantity" />
- <result column="commodity_mode" jdbcType="VARCHAR" property="commodityMode" />
- <result column="commodity_price" jdbcType="DECIMAL" property="commodityPrice" />
- <result column="task_status" jdbcType="INTEGER" property="taskStatus" />
- <result column="task_distribution_time" jdbcType="TIMESTAMP" property="taskDistributionTime" />
- <result column="task_allocator" jdbcType="VARCHAR" property="taskAllocator" />
- <result column="task_receiver" jdbcType="VARCHAR" property="taskReceiver" />
- <result column="task_comment" jdbcType="VARCHAR" property="taskComment" />
- <result column="task_start_time" jdbcType="TIMESTAMP" property="taskStartTime" />
- <result column="task_end_time" jdbcType="TIMESTAMP" property="taskEndTime" />
- <result column="project_status" jdbcType="INTEGER" property="projectStatus" />
- <result column="main" jdbcType="INTEGER" property="main" />
- <result column="accept_time" jdbcType="DATE" property="acceptTime" />
- <result column="review_time" jdbcType="DATE" property="reviewTime" />
- <result column="publicity_time" jdbcType="DATE" property="publicityTime" />
- <result column="licence_time" jdbcType="DATE" property="licenceTime" />
- <result column="name" jdbcType="VARCHAR" property="name" />
- <result column="email" jdbcType="VARCHAR" property="email" />
- </resultMap>
- <resultMap extends="BaseResultMap" id="ResultMapWithBLOBs" type="com.goafanti.common.model.TOrderTask">
- <!--
- WARNING - @mbg.generated
- This element is automatically generated by MyBatis Generator, do not modify.
- This element was generated on Mon Nov 19 11:03:38 CST 2018.
- -->
- <result column="attachment_url" jdbcType="LONGVARCHAR" property="attachmentUrl" />
- </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 Mon Nov 19 11:03:38 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 Mon Nov 19 11:03:38 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 Mon Nov 19 11:03:38 CST 2018.
- -->
- id, order_no, super_id, commodity_id, commodity_name, commodity_quantity, commodity_mode,
- commodity_price, task_status, task_distribution_time, task_allocator, task_receiver,
- task_comment, task_start_time, task_end_time, project_status, accept_time, review_time,
- publicity_time, licence_time ,main
- </sql>
- <sql id="Blob_Column_List">
- <!--
- WARNING - @mbg.generated
- This element is automatically generated by MyBatis Generator, do not modify.
- This element was generated on Mon Nov 19 11:03:38 CST 2018.
- -->
- attachment_url
- </sql>
- <select id="selectByExampleWithBLOBs" parameterType="com.goafanti.common.model.TOrderTaskExample" resultMap="ResultMapWithBLOBs">
- <!--
- WARNING - @mbg.generated
- This element is automatically generated by MyBatis Generator, do not modify.
- This element was generated on Mon Nov 19 11:03:38 CST 2018.
- -->
- select
- <if test="distinct">
- distinct
- </if>
- <include refid="Base_Column_List" />
- ,
- <include refid="Blob_Column_List" />
- from t_order_task
- <if test="_parameter != null">
- <include refid="Example_Where_Clause" />
- </if>
- <if test="orderByClause != null">
- order by ${orderByClause}
- </if>
- </select>
- <select id="selectByExample" parameterType="com.goafanti.common.model.TOrderTaskExample" resultMap="BaseResultMap">
- <!--
- WARNING - @mbg.generated
- This element is automatically generated by MyBatis Generator, do not modify.
- This element was generated on Mon Nov 19 11:03:38 CST 2018.
- -->
- select
- <if test="distinct">
- distinct
- </if>
- <include refid="Base_Column_List" />
- from t_order_task
- <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="ResultMapWithBLOBs">
- <!--
- WARNING - @mbg.generated
- This element is automatically generated by MyBatis Generator, do not modify.
- This element was generated on Mon Nov 19 11:03:38 CST 2018.
- -->
- select
- <include refid="Base_Column_List" />
- ,
- <include refid="Blob_Column_List" />
- from t_order_task
- 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 Mon Nov 19 11:03:38 CST 2018.
- -->
- delete from t_order_task
- where id = #{id,jdbcType=INTEGER}
- </delete>
- <delete id="deleteByExample" parameterType="com.goafanti.common.model.TOrderTaskExample">
- <!--
- WARNING - @mbg.generated
- This element is automatically generated by MyBatis Generator, do not modify.
- This element was generated on Mon Nov 19 11:03:38 CST 2018.
- -->
- delete from t_order_task
- <if test="_parameter != null">
- <include refid="Example_Where_Clause" />
- </if>
- </delete>
- <insert id="insert" parameterType="com.goafanti.common.model.TOrderTask">
- <!--
- WARNING - @mbg.generated
- This element is automatically generated by MyBatis Generator, do not modify.
- This element was generated on Mon Nov 19 11:03:38 CST 2018.
- -->
- insert into t_order_task (id, order_no, super_id,
- commodity_id, commodity_name, commodity_quantity,
- commodity_mode, commodity_price, task_status,
- task_distribution_time, task_allocator,
- task_receiver, task_comment, task_start_time,
- task_end_time, project_status, accept_time,
- review_time, publicity_time, licence_time,
- attachment_url,main)
- values (#{id,jdbcType=INTEGER}, #{orderNo,jdbcType=VARCHAR}, #{superId,jdbcType=VARCHAR},
- #{commodityId,jdbcType=VARCHAR}, #{commodityName,jdbcType=VARCHAR}, #{commodityQuantity,jdbcType=INTEGER},
- #{commodityMode,jdbcType=VARCHAR}, #{commodityPrice,jdbcType=DECIMAL}, #{taskStatus,jdbcType=INTEGER},
- #{taskDistributionTime,jdbcType=TIMESTAMP}, #{taskAllocator,jdbcType=VARCHAR},
- #{taskReceiver,jdbcType=VARCHAR}, #{taskComment,jdbcType=VARCHAR}, #{taskStartTime,jdbcType=TIMESTAMP},
- #{taskEndTime,jdbcType=TIMESTAMP}, #{projectStatus,jdbcType=INTEGER}, #{acceptTime,jdbcType=DATE},
- #{reviewTime,jdbcType=DATE}, #{publicityTime,jdbcType=DATE}, #{licenceTime,jdbcType=DATE},
- #{attachmentUrl,jdbcType=LONGVARCHAR},#{main,jdbcType=INTEGER})
- </insert>
- <insert id="insertSelective" parameterType="com.goafanti.common.model.TOrderTask">
- <!--
- WARNING - @mbg.generated
- This element is automatically generated by MyBatis Generator, do not modify.
- This element was generated on Mon Nov 19 11:03:38 CST 2018.
- -->
- insert into t_order_task
- <trim prefix="(" suffix=")" suffixOverrides=",">
- <if test="id != null">
- id,
- </if>
- <if test="orderNo != null">
- order_no,
- </if>
- <if test="superId != null">
- super_id,
- </if>
- <if test="commodityId != null">
- commodity_id,
- </if>
- <if test="commodityName != null">
- commodity_name,
- </if>
- <if test="commodityQuantity != null">
- commodity_quantity,
- </if>
- <if test="commodityMode != null">
- commodity_mode,
- </if>
- <if test="commodityPrice != null">
- commodity_price,
- </if>
- <if test="taskStatus != null">
- task_status,
- </if>
- <if test="taskDistributionTime != null">
- task_distribution_time,
- </if>
- <if test="taskAllocator != null">
- task_allocator,
- </if>
- <if test="taskReceiver != null">
- task_receiver,
- </if>
- <if test="taskComment != null">
- task_comment,
- </if>
- <if test="taskStartTime != null">
- task_start_time,
- </if>
- <if test="taskEndTime != null">
- task_end_time,
- </if>
- <if test="projectStatus != null">
- project_status,
- </if>
- <if test="acceptTime != null">
- accept_time,
- </if>
- <if test="reviewTime != null">
- review_time,
- </if>
- <if test="publicityTime != null">
- publicity_time,
- </if>
- <if test="licenceTime != null">
- licence_time,
- </if>
- <if test="attachmentUrl != null">
- attachment_url,
- </if>
- <if test="main != null">
- main,
- </if>
- </trim>
- <trim prefix="values (" suffix=")" suffixOverrides=",">
- <if test="id != null">
- #{id,jdbcType=INTEGER},
- </if>
- <if test="orderNo != null">
- #{orderNo,jdbcType=VARCHAR},
- </if>
- <if test="superId != null">
- #{superId,jdbcType=VARCHAR},
- </if>
- <if test="commodityId != null">
- #{commodityId,jdbcType=VARCHAR},
- </if>
- <if test="commodityName != null">
- #{commodityName,jdbcType=VARCHAR},
- </if>
- <if test="commodityQuantity != null">
- #{commodityQuantity,jdbcType=INTEGER},
- </if>
- <if test="commodityMode != null">
- #{commodityMode,jdbcType=VARCHAR},
- </if>
- <if test="commodityPrice != null">
- #{commodityPrice,jdbcType=DECIMAL},
- </if>
- <if test="taskStatus != null">
- #{taskStatus,jdbcType=INTEGER},
- </if>
- <if test="taskDistributionTime != null">
- #{taskDistributionTime,jdbcType=TIMESTAMP},
- </if>
- <if test="taskAllocator != null">
- #{taskAllocator,jdbcType=VARCHAR},
- </if>
- <if test="taskReceiver != null">
- #{taskReceiver,jdbcType=VARCHAR},
- </if>
- <if test="taskComment != null">
- #{taskComment,jdbcType=VARCHAR},
- </if>
- <if test="taskStartTime != null">
- #{taskStartTime,jdbcType=TIMESTAMP},
- </if>
- <if test="taskEndTime != null">
- #{taskEndTime,jdbcType=TIMESTAMP},
- </if>
- <if test="projectStatus != null">
- #{projectStatus,jdbcType=INTEGER},
- </if>
- <if test="acceptTime != null">
- #{acceptTime,jdbcType=DATE},
- </if>
- <if test="reviewTime != null">
- #{reviewTime,jdbcType=DATE},
- </if>
- <if test="publicityTime != null">
- #{publicityTime,jdbcType=DATE},
- </if>
- <if test="licenceTime != null">
- #{licenceTime,jdbcType=DATE},
- </if>
- <if test="attachmentUrl != null">
- #{attachmentUrl,jdbcType=LONGVARCHAR},
- </if>
- <if test="main != null">
- #{main,jdbcType=INTEGER},
- </if>
- </trim>
- </insert>
- <select id="countByExample" parameterType="com.goafanti.common.model.TOrderTaskExample" resultType="java.lang.Long">
- <!--
- WARNING - @mbg.generated
- This element is automatically generated by MyBatis Generator, do not modify.
- This element was generated on Mon Nov 19 11:03:38 CST 2018.
- -->
- select count(*) from t_order_task
- <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 Mon Nov 19 11:03:38 CST 2018.
- -->
- update t_order_task
- <set>
- <if test="record.id != null">
- id = #{record.id,jdbcType=INTEGER},
- </if>
- <if test="record.orderNo != null">
- order_no = #{record.orderNo,jdbcType=VARCHAR},
- </if>
- <if test="record.superId != null">
- super_id = #{record.superId,jdbcType=VARCHAR},
- </if>
- <if test="record.commodityId != null">
- commodity_id = #{record.commodityId,jdbcType=VARCHAR},
- </if>
- <if test="record.commodityName != null">
- commodity_name = #{record.commodityName,jdbcType=VARCHAR},
- </if>
- <if test="record.commodityQuantity != null">
- commodity_quantity = #{record.commodityQuantity,jdbcType=INTEGER},
- </if>
- <if test="record.commodityMode != null">
- commodity_mode = #{record.commodityMode,jdbcType=VARCHAR},
- </if>
- <if test="record.commodityPrice != null">
- commodity_price = #{record.commodityPrice,jdbcType=DECIMAL},
- </if>
- <if test="record.taskStatus != null">
- task_status = #{record.taskStatus,jdbcType=INTEGER},
- </if>
- <if test="record.taskDistributionTime != null">
- task_distribution_time = #{record.taskDistributionTime,jdbcType=TIMESTAMP},
- </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.taskComment != null">
- task_comment = #{record.taskComment,jdbcType=VARCHAR},
- </if>
- <if test="record.taskStartTime != null">
- task_start_time = #{record.taskStartTime,jdbcType=TIMESTAMP},
- </if>
- <if test="record.taskEndTime != null">
- task_end_time = #{record.taskEndTime,jdbcType=TIMESTAMP},
- </if>
- <if test="record.projectStatus != null">
- project_status = #{record.projectStatus,jdbcType=INTEGER},
- </if>
- <if test="record.acceptTime != null">
- accept_time = #{record.acceptTime,jdbcType=DATE},
- </if>
- <if test="record.reviewTime != null">
- review_time = #{record.reviewTime,jdbcType=DATE},
- </if>
- <if test="record.publicityTime != null">
- publicity_time = #{record.publicityTime,jdbcType=DATE},
- </if>
- <if test="record.licenceTime != null">
- licence_time = #{record.licenceTime,jdbcType=DATE},
- </if>
- <if test="record.attachmentUrl != null">
- attachment_url = #{record.attachmentUrl,jdbcType=LONGVARCHAR},
- </if>
- </set>
- <if test="_parameter != null">
- <include refid="Update_By_Example_Where_Clause" />
- </if>
- </update>
- <update id="updateByExampleWithBLOBs" parameterType="map">
- <!--
- WARNING - @mbg.generated
- This element is automatically generated by MyBatis Generator, do not modify.
- This element was generated on Mon Nov 19 11:03:38 CST 2018.
- -->
- update t_order_task
- set id = #{record.id,jdbcType=INTEGER},
- order_no = #{record.orderNo,jdbcType=VARCHAR},
- super_id = #{record.superId,jdbcType=VARCHAR},
- commodity_id = #{record.commodityId,jdbcType=VARCHAR},
- commodity_name = #{record.commodityName,jdbcType=VARCHAR},
- commodity_quantity = #{record.commodityQuantity,jdbcType=INTEGER},
- commodity_mode = #{record.commodityMode,jdbcType=VARCHAR},
- commodity_price = #{record.commodityPrice,jdbcType=DECIMAL},
- task_status = #{record.taskStatus,jdbcType=INTEGER},
- task_distribution_time = #{record.taskDistributionTime,jdbcType=TIMESTAMP},
- task_allocator = #{record.taskAllocator,jdbcType=VARCHAR},
- task_receiver = #{record.taskReceiver,jdbcType=VARCHAR},
- task_comment = #{record.taskComment,jdbcType=VARCHAR},
- task_start_time = #{record.taskStartTime,jdbcType=TIMESTAMP},
- task_end_time = #{record.taskEndTime,jdbcType=TIMESTAMP},
- project_status = #{record.projectStatus,jdbcType=INTEGER},
- accept_time = #{record.acceptTime,jdbcType=DATE},
- review_time = #{record.reviewTime,jdbcType=DATE},
- publicity_time = #{record.publicityTime,jdbcType=DATE},
- licence_time = #{record.licenceTime,jdbcType=DATE},
- attachment_url = #{record.attachmentUrl,jdbcType=LONGVARCHAR}
- <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 Mon Nov 19 11:03:38 CST 2018.
- -->
- update t_order_task
- set id = #{record.id,jdbcType=INTEGER},
- order_no = #{record.orderNo,jdbcType=VARCHAR},
- super_id = #{record.superId,jdbcType=VARCHAR},
- commodity_id = #{record.commodityId,jdbcType=VARCHAR},
- commodity_name = #{record.commodityName,jdbcType=VARCHAR},
- commodity_quantity = #{record.commodityQuantity,jdbcType=INTEGER},
- commodity_mode = #{record.commodityMode,jdbcType=VARCHAR},
- commodity_price = #{record.commodityPrice,jdbcType=DECIMAL},
- task_status = #{record.taskStatus,jdbcType=INTEGER},
- task_distribution_time = #{record.taskDistributionTime,jdbcType=TIMESTAMP},
- task_allocator = #{record.taskAllocator,jdbcType=VARCHAR},
- task_receiver = #{record.taskReceiver,jdbcType=VARCHAR},
- task_comment = #{record.taskComment,jdbcType=VARCHAR},
- task_start_time = #{record.taskStartTime,jdbcType=TIMESTAMP},
- task_end_time = #{record.taskEndTime,jdbcType=TIMESTAMP},
- project_status = #{record.projectStatus,jdbcType=INTEGER},
- accept_time = #{record.acceptTime,jdbcType=DATE},
- review_time = #{record.reviewTime,jdbcType=DATE},
- publicity_time = #{record.publicityTime,jdbcType=DATE},
- licence_time = #{record.licenceTime,jdbcType=DATE}
- <if test="_parameter != null">
- <include refid="Update_By_Example_Where_Clause" />
- </if>
- </update>
- <update id="updateByPrimaryKeySelective" parameterType="com.goafanti.common.model.TOrderTask">
- <!--
- WARNING - @mbg.generated
- This element is automatically generated by MyBatis Generator, do not modify.
- This element was generated on Mon Nov 19 11:03:38 CST 2018.
- -->
- update t_order_task
- <set>
- <if test="orderNo != null">
- order_no = #{orderNo,jdbcType=VARCHAR},
- </if>
- <if test="superId != null">
- super_id = #{superId,jdbcType=VARCHAR},
- </if>
- <if test="commodityId != null">
- commodity_id = #{commodityId,jdbcType=VARCHAR},
- </if>
- <if test="commodityName != null">
- commodity_name = #{commodityName,jdbcType=VARCHAR},
- </if>
- <if test="commodityQuantity != null">
- commodity_quantity = #{commodityQuantity,jdbcType=INTEGER},
- </if>
- <if test="commodityMode != null">
- commodity_mode = #{commodityMode,jdbcType=VARCHAR},
- </if>
- <if test="commodityPrice != null">
- commodity_price = #{commodityPrice,jdbcType=DECIMAL},
- </if>
- <if test="taskStatus != null">
- task_status = #{taskStatus,jdbcType=INTEGER},
- </if>
- <if test="taskDistributionTime != null">
- task_distribution_time = #{taskDistributionTime,jdbcType=TIMESTAMP},
- </if>
- <if test="taskAllocator != null">
- task_allocator = #{taskAllocator,jdbcType=VARCHAR},
- </if>
- <if test="taskReceiver != null">
- task_receiver = #{taskReceiver,jdbcType=VARCHAR},
- </if>
- <if test="taskComment != null">
- task_comment = #{taskComment,jdbcType=VARCHAR},
- </if>
- <if test="taskStartTime != null">
- task_start_time = #{taskStartTime,jdbcType=TIMESTAMP},
- </if>
- <if test="taskEndTime != null">
- task_end_time = #{taskEndTime,jdbcType=TIMESTAMP},
- </if>
- <if test="projectStatus != null">
- project_status = #{projectStatus,jdbcType=INTEGER},
- </if>
- <if test="acceptTime != null">
- accept_time = #{acceptTime,jdbcType=DATE},
- </if>
- <if test="reviewTime != null">
- review_time = #{reviewTime,jdbcType=DATE},
- </if>
- <if test="publicityTime != null">
- publicity_time = #{publicityTime,jdbcType=DATE},
- </if>
- <if test="licenceTime != null">
- licence_time = #{licenceTime,jdbcType=DATE},
- </if>
- <if test="attachmentUrl != null">
- attachment_url = #{attachmentUrl,jdbcType=LONGVARCHAR},
- </if>
- <if test="main != null">
- main = #{main,jdbcType=INTEGER},
- </if>
- </set>
- where id = #{id,jdbcType=INTEGER}
- </update>
- <update id="updateByPrimaryKeyWithBLOBs" parameterType="com.goafanti.common.model.TOrderTask">
- <!--
- WARNING - @mbg.generated
- This element is automatically generated by MyBatis Generator, do not modify.
- This element was generated on Mon Nov 19 11:03:38 CST 2018.
- -->
- update t_order_task
- set order_no = #{orderNo,jdbcType=VARCHAR},
- super_id = #{superId,jdbcType=VARCHAR},
- commodity_id = #{commodityId,jdbcType=VARCHAR},
- commodity_name = #{commodityName,jdbcType=VARCHAR},
- commodity_quantity = #{commodityQuantity,jdbcType=INTEGER},
- commodity_mode = #{commodityMode,jdbcType=VARCHAR},
- commodity_price = #{commodityPrice,jdbcType=DECIMAL},
- task_status = #{taskStatus,jdbcType=INTEGER},
- task_distribution_time = #{taskDistributionTime,jdbcType=TIMESTAMP},
- task_allocator = #{taskAllocator,jdbcType=VARCHAR},
- task_receiver = #{taskReceiver,jdbcType=VARCHAR},
- task_comment = #{taskComment,jdbcType=VARCHAR},
- task_start_time = #{taskStartTime,jdbcType=TIMESTAMP},
- task_end_time = #{taskEndTime,jdbcType=TIMESTAMP},
- project_status = #{projectStatus,jdbcType=INTEGER},
- accept_time = #{acceptTime,jdbcType=DATE},
- review_time = #{reviewTime,jdbcType=DATE},
- publicity_time = #{publicityTime,jdbcType=DATE},
- licence_time = #{licenceTime,jdbcType=DATE},
- attachment_url = #{attachmentUrl,jdbcType=LONGVARCHAR},
- main = #{main,jdbcType=INTEGER}
- where id = #{id,jdbcType=INTEGER}
- </update>
- <update id="updateByPrimaryKey" parameterType="com.goafanti.common.model.TOrderTask">
- <!--
- WARNING - @mbg.generated
- This element is automatically generated by MyBatis Generator, do not modify.
- This element was generated on Mon Nov 19 11:03:38 CST 2018.
- -->
- update t_order_task
- set order_no = #{orderNo,jdbcType=VARCHAR},
- super_id = #{superId,jdbcType=VARCHAR},
- commodity_id = #{commodityId,jdbcType=VARCHAR},
- commodity_name = #{commodityName,jdbcType=VARCHAR},
- commodity_quantity = #{commodityQuantity,jdbcType=INTEGER},
- commodity_mode = #{commodityMode,jdbcType=VARCHAR},
- commodity_price = #{commodityPrice,jdbcType=DECIMAL},
- task_status = #{taskStatus,jdbcType=INTEGER},
- task_distribution_time = #{taskDistributionTime,jdbcType=TIMESTAMP},
- task_allocator = #{taskAllocator,jdbcType=VARCHAR},
- task_receiver = #{taskReceiver,jdbcType=VARCHAR},
- task_comment = #{taskComment,jdbcType=VARCHAR},
- task_start_time = #{taskStartTime,jdbcType=TIMESTAMP},
- task_end_time = #{taskEndTime,jdbcType=TIMESTAMP},
- project_status = #{projectStatus,jdbcType=INTEGER},
- accept_time = #{acceptTime,jdbcType=DATE},
- review_time = #{reviewTime,jdbcType=DATE},
- publicity_time = #{publicityTime,jdbcType=DATE},
- licence_time = #{licenceTime,jdbcType=DATE},
- main = #{main,jdbcType=INTEGER}
- where id = #{id,jdbcType=INTEGER}
- </update>
- <select id="selectOrderTask" resultType="com.goafanti.order.bo.TOrderTaskBo">
- select
- a.id,a.order_no as orderNo,a.commodity_name as commodityName,a.commodity_id as commodityId,
- a.commodity_quantity as commodityQuantity,a.commodity_price as commodityPrice,a.task_comment as taskComment,
- a.task_status as taskStatus,a.project_status as projectStatus,a.main,a.task_receiver as taskReceiver ,
- d.name as contacts,d.contact_mobile as contactsMobile,c.cname
- from t_order_task a left join business_project b on a.commodity_id=b.id
- left join business_category c on b.cid=c.id left join admin d on a.task_receiver=d.id
- where a.super_id is null and a.order_no= #{orderNo,jdbcType=VARCHAR}
- </select>
-
-
- <select id="selectOrderTaskListByPage" resultType="com.goafanti.order.bo.TOrderTaskListBo">
- select a.id,a.commodity_name as taskName,a.order_no as orderNo,c.cname,d.name as receiverName,
- a.project_status as projectStatus,a.task_status as taskStatus,date_format(a.task_distribution_time,'%Y-%m-%d') as taskDate,
- a.commodity_quantity as commodityQuantity,f.nickname as userName,h.name as depName
- from t_order_task a left join business_project b on a.commodity_id=b.id
- left join business_category c on b.cid=c.id
- left join admin d on a.task_receiver=d.id
- left join t_order_new e on a.order_no=e.order_no
- left join user f on e.buyer_id=f.id
- left join admin g on e.salesman_id=g.id
- left join department h on g.department_id=h.id
- where e.delete_sign=0 and e.order_status not in (5,7)
- <if test="specially == 0">
- and a.task_receiver= #{aid,jdbcType=VARCHAR}
- and a.commodity_quantity =1
- </if>
- <if test="specially == 1">
- and a.task_receiver= #{aid,jdbcType=VARCHAR}
- and a.super_id is null
- </if>
- <if test="specially == 2">
- and d.superior_id= (select department_id from admin where id= #{aid,jdbcType=VARCHAR})
- </if>
- <if test="orderNo != null">
- and a.order_no= #{orderNo,jdbcType=VARCHAR}
- </if>
- <if test="depId != null">
- and g.department_id= #{depId,jdbcType=VARCHAR}
- </if>
- <if test="name != null">
- and f.nickname like CONCAT('%',#{name,jdbcType=VARCHAR},'%')
- </if>
- <if test="orderNo != null">
- and a.order_no= #{orderNo,jdbcType=VARCHAR}
- </if>
- <if test="taskId != null">
- and a.id= #{taskId,jdbcType=VARCHAR}
- </if>
- <if test="taskStatus != null">
- and a.task_status= #{taskStatus,jdbcType=INTEGER}
- </if>
- <if test="adminName != null">
- and d.name like CONCAT('%', #{adminName,jdbcType=VARCHAR},'%')
- </if>
- order by a.task_distribution_time desc
- <if test="page_sql!=null">
- ${page_sql}
- </if>
- </select>
-
- <select id="selectOrderTaskListCount" resultType="java.lang.Integer">
- select count(*)
- from t_order_task a
- left join admin d on a.task_receiver=d.id
- left join t_order_new e on a.order_no=e.order_no
- left join admin g on e.salesman_id=g.id
- left join department h on g.department_id=h.id
- where e.delete_sign=0 and e.order_status not in (5,7)
- <if test="specially == 0">
- and a.task_receiver= #{aid,jdbcType=VARCHAR}
- and a.commodity_quantity =1
- </if>
- <if test="specially == 1">
- and a.task_receiver= #{aid,jdbcType=VARCHAR}
- and a.super_id is null
- </if>
- <if test="specially == 2">
- and d.superior_id= (select department_id from admin where id= #{aid,jdbcType=VARCHAR})
- </if>
- <if test="orderNo != null">
- and a.order_no= #{orderNo,jdbcType=VARCHAR}
- </if>
- <if test="depId != null">
- and g.department_id= #{depId,jdbcType=VARCHAR}
- </if>
- <if test="name != null">
- and f.nickname like CONCAT('%',#{name,jdbcType=VARCHAR},'%')
- </if>
- <if test="orderNo != null">
- and a.order_no= #{orderNo,jdbcType=VARCHAR}
- </if>
- <if test="taskId != null">
- and a.id= #{taskId,jdbcType=VARCHAR}
- </if>
- <if test="taskStatus != null">
- and a.task_status= #{taskStatus,jdbcType=INTEGER}
- </if>
- <if test="adminName != null">
- and d.name like CONCAT('%', #{adminName,jdbcType=VARCHAR},'%')
- </if>
- </select>
- <select id="getOrderTaskDetail" resultType="com.goafanti.order.bo.TOrderTaskDetailBo">
- select
- a.id,a.commodity_name as taskName,a.order_no as orderNo,c.cname,d.name as receiverName,a.task_comment as taskComment,
- a.project_status as projectStatus,a.task_status as taskStatus,e.contacts,a.attachment_url as attachmentUrl,
- f.nickname as userName,g.name as salesmanName,date_format(a.task_start_time,'%Y-%m-%d') as startDate,
- date_format(a.task_end_time,'%Y-%m-%d') as endDate,date_format(a.accept_time,'%Y-%m-%d') as acceptDate,
- date_format(a.review_time,'%Y-%m-%d') as reviewDate,date_format(a.publicity_time,'%Y-%m-%d') as publicityDate,
- date_format(a.licence_time,'%Y-%m-%d') as licenceDate,date_format(a.task_distribution_time,'%Y-%m-%d') as taskDate,
- e.contacts ,e.contact_mobile as contactMobile ,e.legal_person as legalPerson,e.legal_person_tel as legalPersonTel
- from t_order_task a left join business_project b on a.commodity_id=b.id
- left join business_category c on b.cid=c.id
- left join admin d on a.task_receiver=d.id
- left join t_order_new e on a.order_no=e.order_no
- left join user f on e.buyer_id=f.id
- left join admin g on e.salesman_id=g.id
- where a.id= #{id,jdbcType=VARCHAR}
- </select>
- <select id="selectBySuperId" resultType="com.goafanti.common.model.TOrderTask">
- select super_id as superId,min(task_status) as taskStatus,min(project_status) as projectStatus,max(main) as main from t_order_task
- where super_id = #{superId,jdbcType=VARCHAR} group by super_id
- </select>
-
- <select id="selectTaskHoursListByPage" resultType="com.goafanti.order.bo.TOrderTaskListBo">
- select a.id,a.commodity_name as taskName,a.order_no as orderNo,c.cname,d.name as receiverName,dep.name as depName,
- a.task_status as taskStatus,f.nickname as userName,ifnull(g.hours,0) as hours,a.commodity_quantity as commodityQuantity
- from t_order_task a left join business_project b on a.commodity_id=b.id
- left join business_category c on b.cid=c.id
- left join admin d on a.task_receiver=d.id
- left join department dep on d.department_id=dep.id
- left join t_order_new e on a.order_no=e.order_no
- left join user f on e.buyer_id=f.id
- left join (select task_id,sum(hours) as hours from t_task_hours group by task_id) g on a.id=g.task_id
- where e.delete_sign=0 and a.super_id is null
- <if test="name != null">
- and f.nickname like CONCAT('%',#{name,jdbcType=VARCHAR},'%')
- </if>
- <if test="taskId != null">
- and a.id= #{taskId,jdbcType=VARCHAR}
- </if>
- <if test="starTime !=null and endTime !=null">
- and a.task_start_time between #{starTime,jdbcType=VARCHAR} and #{endTime,jdbcType=VARCHAR}
- </if>
- order by a.task_start_time desc
- <if test="page_sql!=null">
- ${page_sql}
- </if>
- </select>
-
- <select id="selectTaskHoursListCount" resultType="java.lang.Integer">
- select count(*)
- from t_order_task a left join business_project b on a.commodity_id=b.id
- left join business_category c on b.cid=c.id
- left join admin d on a.task_receiver=d.id
- left join t_order_new e on a.order_no=e.order_no
- left join user f on e.buyer_id=f.id
- where e.delete_sign=0 and a.super_id is null
- <if test="name != null">
- and f.nickname like CONCAT('%',#{name,jdbcType=VARCHAR},'%')
- </if>
- <if test="taskId != null">
- and a.id= #{taskId,jdbcType=VARCHAR}
- </if>
- <if test="starTime !=null and endTime !=null">
- and a.task_start_time between #{starTime,jdbcType=VARCHAR} and #{endTime,jdbcType=VARCHAR}
- </if>
- </select>
-
- <select id="selectTaskListByPage" resultType="com.goafanti.order.bo.TOrderTaskListBo">
- select a.id,a.commodity_name as taskName,a.order_no as orderNo,c.cname,d.name as receiverName,
- a.project_status as projectStatus,a.task_status as taskStatus,date_format(a.task_distribution_time,'%Y-%m-%d') as taskDate,
- a.commodity_quantity as commodityQuantity,f.nickname as userName,h.name as depName
- from t_task_log x left join t_order_task a on x.task_id=a.id
- left join business_project b on a.commodity_id=b.id
- left join business_category c on b.cid=c.id
- left join admin d on a.task_receiver=d.id
- left join t_order_new e on a.order_no=e.order_no
- left join user f on e.buyer_id=f.id
- left join admin g on e.salesman_id=g.id
- left join department h on g.department_id=h.id
- where e.delete_sign=0
- and x.task_receiver= #{aid,jdbcType=VARCHAR}
- <if test="orderNo != null">
- and a.order_no= #{orderNo,jdbcType=VARCHAR}
- </if>
- <if test="name != null">
- and f.nickname like CONCAT('%',#{name,jdbcType=VARCHAR},'%')
- </if>
- <if test="orderNo != null">
- and a.order_no= #{orderNo,jdbcType=VARCHAR}
- </if>
- <if test="depId != null">
- and g.department_id= #{depId ,jdbcType=VARCHAR}
- </if>
- <if test="taskId != null">
- and a.id= #{taskId,jdbcType=VARCHAR}
- </if>
- <if test="taskStatus != null">
- and a.task_status= #{taskStatus,jdbcType=INTEGER}
- </if>
- <if test="adminName != null">
- and d.name like CONCAT('%', #{adminName,jdbcType=VARCHAR},'%')
- </if>
- order by a.task_distribution_time desc
- <if test="page_sql!=null">
- ${page_sql}
- </if>
- </select>
-
- <select id="selectTaskListCount" resultType="java.lang.Integer">
- select count(*)
- from t_task_log x left join t_order_task a on x.task_id=a.id
- left join admin d on a.task_receiver=d.id
- left join t_order_new e on a.order_no=e.order_no
- where e.delete_sign=0
- and x.task_receiver= #{aid,jdbcType=VARCHAR}
- <if test="orderNo != null">
- and a.order_no= #{orderNo,jdbcType=VARCHAR}
- </if>
- <if test="name != null">
- and f.nickname like CONCAT('%',#{name,jdbcType=VARCHAR},'%')
- </if>
- <if test="depId != null">
- and g.department_id= #{depId ,jdbcType=VARCHAR}
- </if>
- <if test="orderNo != null">
- and a.order_no= #{orderNo,jdbcType=VARCHAR}
- </if>
- <if test="taskId != null">
- and a.id= #{taskId,jdbcType=VARCHAR}
- </if>
- <if test="taskStatus != null">
- and a.task_status= #{taskStatus,jdbcType=INTEGER}
- </if>
- <if test="adminName != null">
- and d.name like CONCAT('%', #{adminName,jdbcType=VARCHAR},'%')
- </if>
- </select>
- <!-- 根据订单编号获得所有的任务负责人 -->
- <select id="getReceiverByOid" parameterType="java.lang.String" resultMap="BaseResultMap">
- select distinct task_receiver, a.name, a.email, t.id, t.project_status from t_order_task t
- inner join admin a on t.task_receiver = a.id
- where order_no = #{orderNo,jdbcType=VARCHAR} and task_status > 0 and super_id is null
- </select>
- </mapper>
|