Просмотр исходного кода

外包日志开发

Signed-off-by: anderx <312518615@qq.com>
anderx лет назад: 5
Родитель
Сommit
010c8e9905

+ 1 - 1
GeneratorConfig.xml

@@ -9,6 +9,6 @@
     <javaModelGenerator targetPackage="com.goafanti.common.model" targetProject="kede-server" />
     <sqlMapGenerator targetPackage="com.goafanti.common.mapper" targetProject="kede-server" />
     <javaClientGenerator  targetPackage="com.goafanti.common.dao"  type="XMLMAPPER" targetProject="kede-server"  />
-    <table schema="aft" tableName="payment_node"/>
+    <table schema="aft" tableName="outsource_log"/>
   </context>
 </generatorConfiguration>

+ 79 - 0
src/main/java/com/goafanti/common/dao/OutsourceLogMapper.java

@@ -0,0 +1,79 @@
+package com.goafanti.common.dao;
+
+import com.goafanti.common.model.OutsourceLog;
+import com.goafanti.common.model.OutsourceLogExample;
+import com.goafanti.order.bo.OutOutsourceLog;
+
+import java.util.List;
+import org.apache.ibatis.annotations.Param;
+
+public interface OutsourceLogMapper {
+
+	/**
+	 * This method was generated by MyBatis Generator. This method corresponds to the database table outsource_log
+	 * @mbg.generated  Fri Jun 12 16:30:16 CST 2020
+	 */
+	long countByExample(OutsourceLogExample example);
+
+	/**
+	 * This method was generated by MyBatis Generator. This method corresponds to the database table outsource_log
+	 * @mbg.generated  Fri Jun 12 16:30:16 CST 2020
+	 */
+	int deleteByExample(OutsourceLogExample example);
+
+	/**
+	 * This method was generated by MyBatis Generator. This method corresponds to the database table outsource_log
+	 * @mbg.generated  Fri Jun 12 16:30:16 CST 2020
+	 */
+	int deleteByPrimaryKey(Integer id);
+
+	/**
+	 * This method was generated by MyBatis Generator. This method corresponds to the database table outsource_log
+	 * @mbg.generated  Fri Jun 12 16:30:16 CST 2020
+	 */
+	int insert(OutsourceLog record);
+
+	/**
+	 * This method was generated by MyBatis Generator. This method corresponds to the database table outsource_log
+	 * @mbg.generated  Fri Jun 12 16:30:16 CST 2020
+	 */
+	int insertSelective(OutsourceLog record);
+
+	/**
+	 * This method was generated by MyBatis Generator. This method corresponds to the database table outsource_log
+	 * @mbg.generated  Fri Jun 12 16:30:16 CST 2020
+	 */
+	List<OutsourceLog> selectByExample(OutsourceLogExample example);
+
+	/**
+	 * This method was generated by MyBatis Generator. This method corresponds to the database table outsource_log
+	 * @mbg.generated  Fri Jun 12 16:30:16 CST 2020
+	 */
+	OutsourceLog selectByPrimaryKey(Integer id);
+
+	/**
+	 * This method was generated by MyBatis Generator. This method corresponds to the database table outsource_log
+	 * @mbg.generated  Fri Jun 12 16:30:16 CST 2020
+	 */
+	int updateByExampleSelective(@Param("record") OutsourceLog record, @Param("example") OutsourceLogExample example);
+
+	/**
+	 * This method was generated by MyBatis Generator. This method corresponds to the database table outsource_log
+	 * @mbg.generated  Fri Jun 12 16:30:16 CST 2020
+	 */
+	int updateByExample(@Param("record") OutsourceLog record, @Param("example") OutsourceLogExample example);
+
+	/**
+	 * This method was generated by MyBatis Generator. This method corresponds to the database table outsource_log
+	 * @mbg.generated  Fri Jun 12 16:30:16 CST 2020
+	 */
+	int updateByPrimaryKeySelective(OutsourceLog record);
+
+	/**
+	 * This method was generated by MyBatis Generator. This method corresponds to the database table outsource_log
+	 * @mbg.generated  Fri Jun 12 16:30:16 CST 2020
+	 */
+	int updateByPrimaryKey(OutsourceLog record);
+
+	List<OutOutsourceLog> selectByTid(Integer tid);
+}

+ 323 - 0
src/main/java/com/goafanti/common/mapper/OutsourceLogMapper.xml

@@ -0,0 +1,323 @@
+<?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.OutsourceLogMapper">
+  <resultMap id="BaseResultMap" type="com.goafanti.common.model.OutsourceLog">
+    <!--
+      WARNING - @mbg.generated
+      This element is automatically generated by MyBatis Generator, do not modify.
+      This element was generated on Fri Jun 12 16:30:16 CST 2020.
+    -->
+    <id column="id" jdbcType="INTEGER" property="id" />
+    <result column="tid" jdbcType="INTEGER" property="tid" />
+    <result column="status" jdbcType="INTEGER" property="status" />
+    <result column="remarks" jdbcType="VARCHAR" property="remarks" />
+    <result column="aid" jdbcType="VARCHAR" property="aid" />
+    <result column="aname" jdbcType="VARCHAR" property="aname" />
+    <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 Fri Jun 12 16:30:16 CST 2020.
+    -->
+    <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 Fri Jun 12 16:30:16 CST 2020.
+    -->
+    <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 Fri Jun 12 16:30:16 CST 2020.
+    -->
+    id, tid, status, remarks, aid, aname, create_time
+  </sql>
+  <select id="selectByExample" parameterType="com.goafanti.common.model.OutsourceLogExample" resultMap="BaseResultMap">
+    <!--
+      WARNING - @mbg.generated
+      This element is automatically generated by MyBatis Generator, do not modify.
+      This element was generated on Fri Jun 12 16:30:16 CST 2020.
+    -->
+    select
+    <if test="distinct">
+      distinct
+    </if>
+    <include refid="Base_Column_List" />
+    from outsource_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 Fri Jun 12 16:30:16 CST 2020.
+    -->
+    select 
+    <include refid="Base_Column_List" />
+    from outsource_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 Fri Jun 12 16:30:16 CST 2020.
+    -->
+    delete from outsource_log
+    where id = #{id,jdbcType=INTEGER}
+  </delete>
+  <delete id="deleteByExample" parameterType="com.goafanti.common.model.OutsourceLogExample">
+    <!--
+      WARNING - @mbg.generated
+      This element is automatically generated by MyBatis Generator, do not modify.
+      This element was generated on Fri Jun 12 16:30:16 CST 2020.
+    -->
+    delete from outsource_log
+    <if test="_parameter != null">
+      <include refid="Example_Where_Clause" />
+    </if>
+  </delete>
+  <insert id="insert" parameterType="com.goafanti.common.model.OutsourceLog">
+    <!--
+      WARNING - @mbg.generated
+      This element is automatically generated by MyBatis Generator, do not modify.
+      This element was generated on Fri Jun 12 16:30:16 CST 2020.
+    -->
+    insert into outsource_log (id, tid, status, 
+      remarks, aid, aname, 
+      create_time)
+    values (#{id,jdbcType=INTEGER}, #{tid,jdbcType=INTEGER}, #{status,jdbcType=INTEGER}, 
+      #{remarks,jdbcType=VARCHAR}, #{aid,jdbcType=VARCHAR}, #{aname,jdbcType=VARCHAR}, 
+      #{createTime,jdbcType=TIMESTAMP})
+  </insert>
+  <insert id="insertSelective" parameterType="com.goafanti.common.model.OutsourceLog">
+    <!--
+      WARNING - @mbg.generated
+      This element is automatically generated by MyBatis Generator, do not modify.
+      This element was generated on Fri Jun 12 16:30:16 CST 2020.
+    -->
+    insert into outsource_log
+    <trim prefix="(" suffix=")" suffixOverrides=",">
+      <if test="id != null">
+        id,
+      </if>
+      <if test="tid != null">
+        tid,
+      </if>
+      <if test="status != null">
+        status,
+      </if>
+      <if test="remarks != null">
+        remarks,
+      </if>
+      <if test="aid != null">
+        aid,
+      </if>
+      <if test="aname != null">
+        aname,
+      </if>
+      <if test="createTime != null">
+        create_time,
+      </if>
+    </trim>
+    <trim prefix="values (" suffix=")" suffixOverrides=",">
+      <if test="id != null">
+        #{id,jdbcType=INTEGER},
+      </if>
+      <if test="tid != null">
+        #{tid,jdbcType=INTEGER},
+      </if>
+      <if test="status != null">
+        #{status,jdbcType=INTEGER},
+      </if>
+      <if test="remarks != null">
+        #{remarks,jdbcType=VARCHAR},
+      </if>
+      <if test="aid != null">
+        #{aid,jdbcType=VARCHAR},
+      </if>
+      <if test="aname != null">
+        #{aname,jdbcType=VARCHAR},
+      </if>
+      <if test="createTime != null">
+        #{createTime,jdbcType=TIMESTAMP},
+      </if>
+    </trim>
+  </insert>
+  <select id="countByExample" parameterType="com.goafanti.common.model.OutsourceLogExample" resultType="java.lang.Long">
+    <!--
+      WARNING - @mbg.generated
+      This element is automatically generated by MyBatis Generator, do not modify.
+      This element was generated on Fri Jun 12 16:30:16 CST 2020.
+    -->
+    select count(*) from outsource_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 Fri Jun 12 16:30:16 CST 2020.
+    -->
+    update outsource_log
+    <set>
+      <if test="record.id != null">
+        id = #{record.id,jdbcType=INTEGER},
+      </if>
+      <if test="record.tid != null">
+        tid = #{record.tid,jdbcType=INTEGER},
+      </if>
+      <if test="record.status != null">
+        status = #{record.status,jdbcType=INTEGER},
+      </if>
+      <if test="record.remarks != null">
+        remarks = #{record.remarks,jdbcType=VARCHAR},
+      </if>
+      <if test="record.aid != null">
+        aid = #{record.aid,jdbcType=VARCHAR},
+      </if>
+      <if test="record.aname != null">
+        aname = #{record.aname,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 Fri Jun 12 16:30:16 CST 2020.
+    -->
+    update outsource_log
+    set id = #{record.id,jdbcType=INTEGER},
+      tid = #{record.tid,jdbcType=INTEGER},
+      status = #{record.status,jdbcType=INTEGER},
+      remarks = #{record.remarks,jdbcType=VARCHAR},
+      aid = #{record.aid,jdbcType=VARCHAR},
+      aname = #{record.aname,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.OutsourceLog">
+    <!--
+      WARNING - @mbg.generated
+      This element is automatically generated by MyBatis Generator, do not modify.
+      This element was generated on Fri Jun 12 16:30:16 CST 2020.
+    -->
+    update outsource_log
+    <set>
+      <if test="tid != null">
+        tid = #{tid,jdbcType=INTEGER},
+      </if>
+      <if test="status != null">
+        status = #{status,jdbcType=INTEGER},
+      </if>
+      <if test="remarks != null">
+        remarks = #{remarks,jdbcType=VARCHAR},
+      </if>
+      <if test="aid != null">
+        aid = #{aid,jdbcType=VARCHAR},
+      </if>
+      <if test="aname != null">
+        aname = #{aname,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.OutsourceLog">
+    <!--
+      WARNING - @mbg.generated
+      This element is automatically generated by MyBatis Generator, do not modify.
+      This element was generated on Fri Jun 12 16:30:16 CST 2020.
+    -->
+    update outsource_log
+    set tid = #{tid,jdbcType=INTEGER},
+      status = #{status,jdbcType=INTEGER},
+      remarks = #{remarks,jdbcType=VARCHAR},
+      aid = #{aid,jdbcType=VARCHAR},
+      aname = #{aname,jdbcType=VARCHAR},
+      create_time = #{createTime,jdbcType=TIMESTAMP}
+    where id = #{id,jdbcType=INTEGER}
+  </update>
+  
+  <select id="selectByTid" resultType="com.goafanti.order.bo.OutOutsourceLog">
+  SELECT id, tid, status, remarks, aid, aname, date_format(create_time,'%Y-%m-%d')createTimes FROM outsource_log 
+WHERE tid= #{tid}
+  </select>
+</mapper>

+ 194 - 0
src/main/java/com/goafanti/common/model/OutsourceLog.java

@@ -0,0 +1,194 @@
+package com.goafanti.common.model;
+
+import java.util.Date;
+
+public class OutsourceLog {
+    /**
+	 * This field was generated by MyBatis Generator. This field corresponds to the database column outsource_log.id
+	 * @mbg.generated  Fri Jun 12 16:30:16 CST 2020
+	 */
+	private Integer id;
+	/**
+	 * This field was generated by MyBatis Generator. This field corresponds to the database column outsource_log.tid
+	 * @mbg.generated  Fri Jun 12 16:30:16 CST 2020
+	 */
+	private Integer tid;
+	/**
+	 * This field was generated by MyBatis Generator. This field corresponds to the database column outsource_log.status
+	 * @mbg.generated  Fri Jun 12 16:30:16 CST 2020
+	 */
+	private Integer status;
+	/**
+	 * This field was generated by MyBatis Generator. This field corresponds to the database column outsource_log.remarks
+	 * @mbg.generated  Fri Jun 12 16:30:16 CST 2020
+	 */
+	private String remarks;
+	/**
+	 * This field was generated by MyBatis Generator. This field corresponds to the database column outsource_log.aid
+	 * @mbg.generated  Fri Jun 12 16:30:16 CST 2020
+	 */
+	private String aid;
+	/**
+	 * This field was generated by MyBatis Generator. This field corresponds to the database column outsource_log.aname
+	 * @mbg.generated  Fri Jun 12 16:30:16 CST 2020
+	 */
+	private String aname;
+	/**
+	 * This field was generated by MyBatis Generator. This field corresponds to the database column outsource_log.create_time
+	 * @mbg.generated  Fri Jun 12 16:30:16 CST 2020
+	 */
+	private Date createTime;
+
+
+	/**
+	 * This method was generated by MyBatis Generator. This method returns the value of the database column outsource_log.id
+	 * @return  the value of outsource_log.id
+	 * @mbg.generated  Fri Jun 12 16:30:16 CST 2020
+	 */
+	public Integer getId() {
+		return id;
+	}
+
+
+	/**
+	 * This method was generated by MyBatis Generator. This method sets the value of the database column outsource_log.id
+	 * @param id  the value for outsource_log.id
+	 * @mbg.generated  Fri Jun 12 16:30:16 CST 2020
+	 */
+	public void setId(Integer id) {
+		this.id = id;
+	}
+
+
+	/**
+	 * This method was generated by MyBatis Generator. This method returns the value of the database column outsource_log.tid
+	 * @return  the value of outsource_log.tid
+	 * @mbg.generated  Fri Jun 12 16:30:16 CST 2020
+	 */
+	public Integer getTid() {
+		return tid;
+	}
+
+
+	/**
+	 * This method was generated by MyBatis Generator. This method sets the value of the database column outsource_log.tid
+	 * @param tid  the value for outsource_log.tid
+	 * @mbg.generated  Fri Jun 12 16:30:16 CST 2020
+	 */
+	public void setTid(Integer tid) {
+		this.tid = tid;
+	}
+
+
+	/**
+	 * This method was generated by MyBatis Generator. This method returns the value of the database column outsource_log.status
+	 * @return  the value of outsource_log.status
+	 * @mbg.generated  Fri Jun 12 16:30:16 CST 2020
+	 */
+	public Integer getStatus() {
+		return status;
+	}
+
+
+	/**
+	 * This method was generated by MyBatis Generator. This method sets the value of the database column outsource_log.status
+	 * @param status  the value for outsource_log.status
+	 * @mbg.generated  Fri Jun 12 16:30:16 CST 2020
+	 */
+	public void setStatus(Integer status) {
+		this.status = status;
+	}
+
+
+	/**
+	 * This method was generated by MyBatis Generator. This method returns the value of the database column outsource_log.remarks
+	 * @return  the value of outsource_log.remarks
+	 * @mbg.generated  Fri Jun 12 16:30:16 CST 2020
+	 */
+	public String getRemarks() {
+		return remarks;
+	}
+
+
+	/**
+	 * This method was generated by MyBatis Generator. This method sets the value of the database column outsource_log.remarks
+	 * @param remarks  the value for outsource_log.remarks
+	 * @mbg.generated  Fri Jun 12 16:30:16 CST 2020
+	 */
+	public void setRemarks(String remarks) {
+		this.remarks = remarks;
+	}
+
+
+	/**
+	 * This method was generated by MyBatis Generator. This method returns the value of the database column outsource_log.aid
+	 * @return  the value of outsource_log.aid
+	 * @mbg.generated  Fri Jun 12 16:30:16 CST 2020
+	 */
+	public String getAid() {
+		return aid;
+	}
+
+
+	/**
+	 * This method was generated by MyBatis Generator. This method sets the value of the database column outsource_log.aid
+	 * @param aid  the value for outsource_log.aid
+	 * @mbg.generated  Fri Jun 12 16:30:16 CST 2020
+	 */
+	public void setAid(String aid) {
+		this.aid = aid;
+	}
+
+
+	/**
+	 * This method was generated by MyBatis Generator. This method returns the value of the database column outsource_log.aname
+	 * @return  the value of outsource_log.aname
+	 * @mbg.generated  Fri Jun 12 16:30:16 CST 2020
+	 */
+	public String getAname() {
+		return aname;
+	}
+
+
+	/**
+	 * This method was generated by MyBatis Generator. This method sets the value of the database column outsource_log.aname
+	 * @param aname  the value for outsource_log.aname
+	 * @mbg.generated  Fri Jun 12 16:30:16 CST 2020
+	 */
+	public void setAname(String aname) {
+		this.aname = aname;
+	}
+
+
+	/**
+	 * This method was generated by MyBatis Generator. This method returns the value of the database column outsource_log.create_time
+	 * @return  the value of outsource_log.create_time
+	 * @mbg.generated  Fri Jun 12 16:30:16 CST 2020
+	 */
+	public Date getCreateTime() {
+		return createTime;
+	}
+
+
+	/**
+	 * This method was generated by MyBatis Generator. This method sets the value of the database column outsource_log.create_time
+	 * @param createTime  the value for outsource_log.create_time
+	 * @mbg.generated  Fri Jun 12 16:30:16 CST 2020
+	 */
+	public void setCreateTime(Date createTime) {
+		this.createTime = createTime;
+	}
+
+	public OutsourceLog() {}
+	
+	public OutsourceLog(Integer tid, Integer status,String remarks,String aid,String aname) {
+    	this.tid=tid;
+    	this.status=status;
+    	this.remarks=remarks;
+    	this.aid=aid;
+    	this.aname=aname;
+    }
+    
+    
+    
+}

+ 712 - 0
src/main/java/com/goafanti/common/model/OutsourceLogExample.java

@@ -0,0 +1,712 @@
+package com.goafanti.common.model;
+
+import java.util.ArrayList;
+import java.util.Date;
+import java.util.List;
+
+public class OutsourceLogExample {
+    /**
+	 * This field was generated by MyBatis Generator. This field corresponds to the database table outsource_log
+	 * @mbg.generated  Fri Jun 12 16:30:16 CST 2020
+	 */
+	protected String orderByClause;
+	/**
+	 * This field was generated by MyBatis Generator. This field corresponds to the database table outsource_log
+	 * @mbg.generated  Fri Jun 12 16:30:16 CST 2020
+	 */
+	protected boolean distinct;
+	/**
+	 * This field was generated by MyBatis Generator. This field corresponds to the database table outsource_log
+	 * @mbg.generated  Fri Jun 12 16:30:16 CST 2020
+	 */
+	protected List<Criteria> oredCriteria;
+
+	/**
+	 * This method was generated by MyBatis Generator. This method corresponds to the database table outsource_log
+	 * @mbg.generated  Fri Jun 12 16:30:16 CST 2020
+	 */
+	public OutsourceLogExample() {
+		oredCriteria = new ArrayList<Criteria>();
+	}
+
+	/**
+	 * This method was generated by MyBatis Generator. This method corresponds to the database table outsource_log
+	 * @mbg.generated  Fri Jun 12 16:30:16 CST 2020
+	 */
+	public void setOrderByClause(String orderByClause) {
+		this.orderByClause = orderByClause;
+	}
+
+	/**
+	 * This method was generated by MyBatis Generator. This method corresponds to the database table outsource_log
+	 * @mbg.generated  Fri Jun 12 16:30:16 CST 2020
+	 */
+	public String getOrderByClause() {
+		return orderByClause;
+	}
+
+	/**
+	 * This method was generated by MyBatis Generator. This method corresponds to the database table outsource_log
+	 * @mbg.generated  Fri Jun 12 16:30:16 CST 2020
+	 */
+	public void setDistinct(boolean distinct) {
+		this.distinct = distinct;
+	}
+
+	/**
+	 * This method was generated by MyBatis Generator. This method corresponds to the database table outsource_log
+	 * @mbg.generated  Fri Jun 12 16:30:16 CST 2020
+	 */
+	public boolean isDistinct() {
+		return distinct;
+	}
+
+	/**
+	 * This method was generated by MyBatis Generator. This method corresponds to the database table outsource_log
+	 * @mbg.generated  Fri Jun 12 16:30:16 CST 2020
+	 */
+	public List<Criteria> getOredCriteria() {
+		return oredCriteria;
+	}
+
+	/**
+	 * This method was generated by MyBatis Generator. This method corresponds to the database table outsource_log
+	 * @mbg.generated  Fri Jun 12 16:30:16 CST 2020
+	 */
+	public void or(Criteria criteria) {
+		oredCriteria.add(criteria);
+	}
+
+	/**
+	 * This method was generated by MyBatis Generator. This method corresponds to the database table outsource_log
+	 * @mbg.generated  Fri Jun 12 16:30:16 CST 2020
+	 */
+	public Criteria or() {
+		Criteria criteria = createCriteriaInternal();
+		oredCriteria.add(criteria);
+		return criteria;
+	}
+
+	/**
+	 * This method was generated by MyBatis Generator. This method corresponds to the database table outsource_log
+	 * @mbg.generated  Fri Jun 12 16:30:16 CST 2020
+	 */
+	public Criteria createCriteria() {
+		Criteria criteria = createCriteriaInternal();
+		if (oredCriteria.size() == 0) {
+			oredCriteria.add(criteria);
+		}
+		return criteria;
+	}
+
+	/**
+	 * This method was generated by MyBatis Generator. This method corresponds to the database table outsource_log
+	 * @mbg.generated  Fri Jun 12 16:30:16 CST 2020
+	 */
+	protected Criteria createCriteriaInternal() {
+		Criteria criteria = new Criteria();
+		return criteria;
+	}
+
+	/**
+	 * This method was generated by MyBatis Generator. This method corresponds to the database table outsource_log
+	 * @mbg.generated  Fri Jun 12 16:30:16 CST 2020
+	 */
+	public void clear() {
+		oredCriteria.clear();
+		orderByClause = null;
+		distinct = false;
+	}
+
+	/**
+	 * This class was generated by MyBatis Generator. This class corresponds to the database table outsource_log
+	 * @mbg.generated  Fri Jun 12 16:30:16 CST 2020
+	 */
+	protected abstract static class GeneratedCriteria {
+		protected List<Criterion> criteria;
+
+		protected GeneratedCriteria() {
+			super();
+			criteria = new ArrayList<Criterion>();
+		}
+
+		public boolean isValid() {
+			return criteria.size() > 0;
+		}
+
+		public List<Criterion> getAllCriteria() {
+			return criteria;
+		}
+
+		public List<Criterion> getCriteria() {
+			return criteria;
+		}
+
+		protected void addCriterion(String condition) {
+			if (condition == null) {
+				throw new RuntimeException("Value for condition cannot be null");
+			}
+			criteria.add(new Criterion(condition));
+		}
+
+		protected void addCriterion(String condition, Object value, String property) {
+			if (value == null) {
+				throw new RuntimeException("Value for " + property + " cannot be null");
+			}
+			criteria.add(new Criterion(condition, value));
+		}
+
+		protected void addCriterion(String condition, Object value1, Object value2, String property) {
+			if (value1 == null || value2 == null) {
+				throw new RuntimeException("Between values for " + property + " cannot be null");
+			}
+			criteria.add(new Criterion(condition, value1, value2));
+		}
+
+		public Criteria andIdIsNull() {
+			addCriterion("id is null");
+			return (Criteria) this;
+		}
+
+		public Criteria andIdIsNotNull() {
+			addCriterion("id is not null");
+			return (Criteria) this;
+		}
+
+		public Criteria andIdEqualTo(Integer value) {
+			addCriterion("id =", value, "id");
+			return (Criteria) this;
+		}
+
+		public Criteria andIdNotEqualTo(Integer value) {
+			addCriterion("id <>", value, "id");
+			return (Criteria) this;
+		}
+
+		public Criteria andIdGreaterThan(Integer value) {
+			addCriterion("id >", value, "id");
+			return (Criteria) this;
+		}
+
+		public Criteria andIdGreaterThanOrEqualTo(Integer value) {
+			addCriterion("id >=", value, "id");
+			return (Criteria) this;
+		}
+
+		public Criteria andIdLessThan(Integer value) {
+			addCriterion("id <", value, "id");
+			return (Criteria) this;
+		}
+
+		public Criteria andIdLessThanOrEqualTo(Integer value) {
+			addCriterion("id <=", value, "id");
+			return (Criteria) this;
+		}
+
+		public Criteria andIdIn(List<Integer> values) {
+			addCriterion("id in", values, "id");
+			return (Criteria) this;
+		}
+
+		public Criteria andIdNotIn(List<Integer> values) {
+			addCriterion("id not in", values, "id");
+			return (Criteria) this;
+		}
+
+		public Criteria andIdBetween(Integer value1, Integer value2) {
+			addCriterion("id between", value1, value2, "id");
+			return (Criteria) this;
+		}
+
+		public Criteria andIdNotBetween(Integer value1, Integer value2) {
+			addCriterion("id not between", value1, value2, "id");
+			return (Criteria) this;
+		}
+
+		public Criteria andTidIsNull() {
+			addCriterion("tid is null");
+			return (Criteria) this;
+		}
+
+		public Criteria andTidIsNotNull() {
+			addCriterion("tid is not null");
+			return (Criteria) this;
+		}
+
+		public Criteria andTidEqualTo(Integer value) {
+			addCriterion("tid =", value, "tid");
+			return (Criteria) this;
+		}
+
+		public Criteria andTidNotEqualTo(Integer value) {
+			addCriterion("tid <>", value, "tid");
+			return (Criteria) this;
+		}
+
+		public Criteria andTidGreaterThan(Integer value) {
+			addCriterion("tid >", value, "tid");
+			return (Criteria) this;
+		}
+
+		public Criteria andTidGreaterThanOrEqualTo(Integer value) {
+			addCriterion("tid >=", value, "tid");
+			return (Criteria) this;
+		}
+
+		public Criteria andTidLessThan(Integer value) {
+			addCriterion("tid <", value, "tid");
+			return (Criteria) this;
+		}
+
+		public Criteria andTidLessThanOrEqualTo(Integer value) {
+			addCriterion("tid <=", value, "tid");
+			return (Criteria) this;
+		}
+
+		public Criteria andTidIn(List<Integer> values) {
+			addCriterion("tid in", values, "tid");
+			return (Criteria) this;
+		}
+
+		public Criteria andTidNotIn(List<Integer> values) {
+			addCriterion("tid not in", values, "tid");
+			return (Criteria) this;
+		}
+
+		public Criteria andTidBetween(Integer value1, Integer value2) {
+			addCriterion("tid between", value1, value2, "tid");
+			return (Criteria) this;
+		}
+
+		public Criteria andTidNotBetween(Integer value1, Integer value2) {
+			addCriterion("tid not between", value1, value2, "tid");
+			return (Criteria) this;
+		}
+
+		public Criteria andStatusIsNull() {
+			addCriterion("status is null");
+			return (Criteria) this;
+		}
+
+		public Criteria andStatusIsNotNull() {
+			addCriterion("status is not null");
+			return (Criteria) this;
+		}
+
+		public Criteria andStatusEqualTo(Integer value) {
+			addCriterion("status =", value, "status");
+			return (Criteria) this;
+		}
+
+		public Criteria andStatusNotEqualTo(Integer value) {
+			addCriterion("status <>", value, "status");
+			return (Criteria) this;
+		}
+
+		public Criteria andStatusGreaterThan(Integer value) {
+			addCriterion("status >", value, "status");
+			return (Criteria) this;
+		}
+
+		public Criteria andStatusGreaterThanOrEqualTo(Integer value) {
+			addCriterion("status >=", value, "status");
+			return (Criteria) this;
+		}
+
+		public Criteria andStatusLessThan(Integer value) {
+			addCriterion("status <", value, "status");
+			return (Criteria) this;
+		}
+
+		public Criteria andStatusLessThanOrEqualTo(Integer value) {
+			addCriterion("status <=", value, "status");
+			return (Criteria) this;
+		}
+
+		public Criteria andStatusIn(List<Integer> values) {
+			addCriterion("status in", values, "status");
+			return (Criteria) this;
+		}
+
+		public Criteria andStatusNotIn(List<Integer> values) {
+			addCriterion("status not in", values, "status");
+			return (Criteria) this;
+		}
+
+		public Criteria andStatusBetween(Integer value1, Integer value2) {
+			addCriterion("status between", value1, value2, "status");
+			return (Criteria) this;
+		}
+
+		public Criteria andStatusNotBetween(Integer value1, Integer value2) {
+			addCriterion("status not between", value1, value2, "status");
+			return (Criteria) this;
+		}
+
+		public Criteria andRemarksIsNull() {
+			addCriterion("remarks is null");
+			return (Criteria) this;
+		}
+
+		public Criteria andRemarksIsNotNull() {
+			addCriterion("remarks is not null");
+			return (Criteria) this;
+		}
+
+		public Criteria andRemarksEqualTo(String value) {
+			addCriterion("remarks =", value, "remarks");
+			return (Criteria) this;
+		}
+
+		public Criteria andRemarksNotEqualTo(String value) {
+			addCriterion("remarks <>", value, "remarks");
+			return (Criteria) this;
+		}
+
+		public Criteria andRemarksGreaterThan(String value) {
+			addCriterion("remarks >", value, "remarks");
+			return (Criteria) this;
+		}
+
+		public Criteria andRemarksGreaterThanOrEqualTo(String value) {
+			addCriterion("remarks >=", value, "remarks");
+			return (Criteria) this;
+		}
+
+		public Criteria andRemarksLessThan(String value) {
+			addCriterion("remarks <", value, "remarks");
+			return (Criteria) this;
+		}
+
+		public Criteria andRemarksLessThanOrEqualTo(String value) {
+			addCriterion("remarks <=", value, "remarks");
+			return (Criteria) this;
+		}
+
+		public Criteria andRemarksLike(String value) {
+			addCriterion("remarks like", value, "remarks");
+			return (Criteria) this;
+		}
+
+		public Criteria andRemarksNotLike(String value) {
+			addCriterion("remarks not like", value, "remarks");
+			return (Criteria) this;
+		}
+
+		public Criteria andRemarksIn(List<String> values) {
+			addCriterion("remarks in", values, "remarks");
+			return (Criteria) this;
+		}
+
+		public Criteria andRemarksNotIn(List<String> values) {
+			addCriterion("remarks not in", values, "remarks");
+			return (Criteria) this;
+		}
+
+		public Criteria andRemarksBetween(String value1, String value2) {
+			addCriterion("remarks between", value1, value2, "remarks");
+			return (Criteria) this;
+		}
+
+		public Criteria andRemarksNotBetween(String value1, String value2) {
+			addCriterion("remarks not between", value1, value2, "remarks");
+			return (Criteria) this;
+		}
+
+		public Criteria andAidIsNull() {
+			addCriterion("aid is null");
+			return (Criteria) this;
+		}
+
+		public Criteria andAidIsNotNull() {
+			addCriterion("aid is not null");
+			return (Criteria) this;
+		}
+
+		public Criteria andAidEqualTo(String value) {
+			addCriterion("aid =", value, "aid");
+			return (Criteria) this;
+		}
+
+		public Criteria andAidNotEqualTo(String value) {
+			addCriterion("aid <>", value, "aid");
+			return (Criteria) this;
+		}
+
+		public Criteria andAidGreaterThan(String value) {
+			addCriterion("aid >", value, "aid");
+			return (Criteria) this;
+		}
+
+		public Criteria andAidGreaterThanOrEqualTo(String value) {
+			addCriterion("aid >=", value, "aid");
+			return (Criteria) this;
+		}
+
+		public Criteria andAidLessThan(String value) {
+			addCriterion("aid <", value, "aid");
+			return (Criteria) this;
+		}
+
+		public Criteria andAidLessThanOrEqualTo(String value) {
+			addCriterion("aid <=", value, "aid");
+			return (Criteria) this;
+		}
+
+		public Criteria andAidLike(String value) {
+			addCriterion("aid like", value, "aid");
+			return (Criteria) this;
+		}
+
+		public Criteria andAidNotLike(String value) {
+			addCriterion("aid not like", value, "aid");
+			return (Criteria) this;
+		}
+
+		public Criteria andAidIn(List<String> values) {
+			addCriterion("aid in", values, "aid");
+			return (Criteria) this;
+		}
+
+		public Criteria andAidNotIn(List<String> values) {
+			addCriterion("aid not in", values, "aid");
+			return (Criteria) this;
+		}
+
+		public Criteria andAidBetween(String value1, String value2) {
+			addCriterion("aid between", value1, value2, "aid");
+			return (Criteria) this;
+		}
+
+		public Criteria andAidNotBetween(String value1, String value2) {
+			addCriterion("aid not between", value1, value2, "aid");
+			return (Criteria) this;
+		}
+
+		public Criteria andAnameIsNull() {
+			addCriterion("aname is null");
+			return (Criteria) this;
+		}
+
+		public Criteria andAnameIsNotNull() {
+			addCriterion("aname is not null");
+			return (Criteria) this;
+		}
+
+		public Criteria andAnameEqualTo(String value) {
+			addCriterion("aname =", value, "aname");
+			return (Criteria) this;
+		}
+
+		public Criteria andAnameNotEqualTo(String value) {
+			addCriterion("aname <>", value, "aname");
+			return (Criteria) this;
+		}
+
+		public Criteria andAnameGreaterThan(String value) {
+			addCriterion("aname >", value, "aname");
+			return (Criteria) this;
+		}
+
+		public Criteria andAnameGreaterThanOrEqualTo(String value) {
+			addCriterion("aname >=", value, "aname");
+			return (Criteria) this;
+		}
+
+		public Criteria andAnameLessThan(String value) {
+			addCriterion("aname <", value, "aname");
+			return (Criteria) this;
+		}
+
+		public Criteria andAnameLessThanOrEqualTo(String value) {
+			addCriterion("aname <=", value, "aname");
+			return (Criteria) this;
+		}
+
+		public Criteria andAnameLike(String value) {
+			addCriterion("aname like", value, "aname");
+			return (Criteria) this;
+		}
+
+		public Criteria andAnameNotLike(String value) {
+			addCriterion("aname not like", value, "aname");
+			return (Criteria) this;
+		}
+
+		public Criteria andAnameIn(List<String> values) {
+			addCriterion("aname in", values, "aname");
+			return (Criteria) this;
+		}
+
+		public Criteria andAnameNotIn(List<String> values) {
+			addCriterion("aname not in", values, "aname");
+			return (Criteria) this;
+		}
+
+		public Criteria andAnameBetween(String value1, String value2) {
+			addCriterion("aname between", value1, value2, "aname");
+			return (Criteria) this;
+		}
+
+		public Criteria andAnameNotBetween(String value1, String value2) {
+			addCriterion("aname not between", value1, value2, "aname");
+			return (Criteria) this;
+		}
+
+		public Criteria andCreateTimeIsNull() {
+			addCriterion("create_time is null");
+			return (Criteria) this;
+		}
+
+		public Criteria andCreateTimeIsNotNull() {
+			addCriterion("create_time is not null");
+			return (Criteria) this;
+		}
+
+		public Criteria andCreateTimeEqualTo(Date value) {
+			addCriterion("create_time =", value, "createTime");
+			return (Criteria) this;
+		}
+
+		public Criteria andCreateTimeNotEqualTo(Date value) {
+			addCriterion("create_time <>", value, "createTime");
+			return (Criteria) this;
+		}
+
+		public Criteria andCreateTimeGreaterThan(Date value) {
+			addCriterion("create_time >", value, "createTime");
+			return (Criteria) this;
+		}
+
+		public Criteria andCreateTimeGreaterThanOrEqualTo(Date value) {
+			addCriterion("create_time >=", value, "createTime");
+			return (Criteria) this;
+		}
+
+		public Criteria andCreateTimeLessThan(Date value) {
+			addCriterion("create_time <", value, "createTime");
+			return (Criteria) this;
+		}
+
+		public Criteria andCreateTimeLessThanOrEqualTo(Date value) {
+			addCriterion("create_time <=", value, "createTime");
+			return (Criteria) this;
+		}
+
+		public Criteria andCreateTimeIn(List<Date> values) {
+			addCriterion("create_time in", values, "createTime");
+			return (Criteria) this;
+		}
+
+		public Criteria andCreateTimeNotIn(List<Date> values) {
+			addCriterion("create_time not in", values, "createTime");
+			return (Criteria) this;
+		}
+
+		public Criteria andCreateTimeBetween(Date value1, Date value2) {
+			addCriterion("create_time between", value1, value2, "createTime");
+			return (Criteria) this;
+		}
+
+		public Criteria andCreateTimeNotBetween(Date value1, Date value2) {
+			addCriterion("create_time not between", value1, value2, "createTime");
+			return (Criteria) this;
+		}
+	}
+
+	/**
+	 * This class was generated by MyBatis Generator. This class corresponds to the database table outsource_log
+	 * @mbg.generated  Fri Jun 12 16:30:16 CST 2020
+	 */
+	public static class Criterion {
+		private String condition;
+		private Object value;
+		private Object secondValue;
+		private boolean noValue;
+		private boolean singleValue;
+		private boolean betweenValue;
+		private boolean listValue;
+		private String typeHandler;
+
+		public String getCondition() {
+			return condition;
+		}
+
+		public Object getValue() {
+			return value;
+		}
+
+		public Object getSecondValue() {
+			return secondValue;
+		}
+
+		public boolean isNoValue() {
+			return noValue;
+		}
+
+		public boolean isSingleValue() {
+			return singleValue;
+		}
+
+		public boolean isBetweenValue() {
+			return betweenValue;
+		}
+
+		public boolean isListValue() {
+			return listValue;
+		}
+
+		public String getTypeHandler() {
+			return typeHandler;
+		}
+
+		protected Criterion(String condition) {
+			super();
+			this.condition = condition;
+			this.typeHandler = null;
+			this.noValue = true;
+		}
+
+		protected Criterion(String condition, Object value, String typeHandler) {
+			super();
+			this.condition = condition;
+			this.value = value;
+			this.typeHandler = typeHandler;
+			if (value instanceof List<?>) {
+				this.listValue = true;
+			} else {
+				this.singleValue = true;
+			}
+		}
+
+		protected Criterion(String condition, Object value) {
+			this(condition, value, null);
+		}
+
+		protected Criterion(String condition, Object value, Object secondValue, String typeHandler) {
+			super();
+			this.condition = condition;
+			this.value = value;
+			this.secondValue = secondValue;
+			this.typeHandler = typeHandler;
+			this.betweenValue = true;
+		}
+
+		protected Criterion(String condition, Object value, Object secondValue) {
+			this(condition, value, secondValue, null);
+		}
+	}
+
+	/**
+     * This class was generated by MyBatis Generator.
+     * This class corresponds to the database table outsource_log
+     *
+     * @mbg.generated do_not_delete_during_merge Fri Jun 12 16:24:43 CST 2020
+     */
+    public static class Criteria extends GeneratedCriteria {
+
+        protected Criteria() {
+            super();
+        }
+    }
+}

+ 15 - 0
src/main/java/com/goafanti/order/bo/OutOutsourceLog.java

@@ -0,0 +1,15 @@
+package com.goafanti.order.bo;
+
+import com.goafanti.common.model.OutsourceLog;
+
+public class OutOutsourceLog extends OutsourceLog{
+	private String createTimes;
+
+	public String getCreateTimes() {
+		return createTimes;
+	}
+
+	public void setCreateTimes(String createTimes) {
+		this.createTimes = createTimes;
+	}
+}

+ 14 - 0
src/main/java/com/goafanti/order/controller/OutsourceOrgApiController.java

@@ -179,6 +179,20 @@ public class OutsourceOrgApiController extends CertifyApiController {
 		res.data(outsourceOrgService.updateAuditOutsource(o));
 		return res;
 	}
+	
+	/**
+	 * 外包审核
+	 */
+	@RequestMapping(value="/selectOutsourceLog", method = RequestMethod.GET)
+	public Result selectOutsourceLog(Integer tid){
+		Result res=new Result();
+		if (tid==null) {
+			res.getError().add(buildError(ErrorConstants.PARAM_ERROR, "项目id","项目id"));
+			return res;
+		}
+		res.data(outsourceOrgService.selectOutsourceLog(tid));
+		return res;
+	}
 	 /**
      *	 下载文档
      * 

+ 3 - 0
src/main/java/com/goafanti/order/service/OutsourceOrgService.java

@@ -6,6 +6,7 @@ import com.goafanti.common.model.OutsourceOrganization;
 import com.goafanti.core.mybatis.page.Pagination;
 import com.goafanti.order.bo.OrderOutsourceBo;
 import com.goafanti.order.bo.OrderOutsourceDtails;
+import com.goafanti.order.bo.OutOutsourceLog;
 import com.goafanti.order.bo.OutsourceOrganizationBo;
 
 public interface OutsourceOrgService {
@@ -30,5 +31,7 @@ public interface OutsourceOrgService {
 	Pagination<OrderOutsourceBo> salesmanOrderOutsourceList(String name, String contractNo, String starTime, String endTime,
 			Integer refundStatus, Integer pageNo, Integer pageSize);
 
+	List<OutOutsourceLog> selectOutsourceLog(Integer tid);
+
 	
 }

+ 7 - 0
src/main/java/com/goafanti/order/service/impl/OrderNewServiceImpl.java

@@ -43,6 +43,7 @@ import com.goafanti.common.dao.NewOrderDunMapper;
 import com.goafanti.common.dao.NoticeMapper;
 import com.goafanti.common.dao.OrganizationContactBookMapper;
 import com.goafanti.common.dao.OrganizationManagementMapper;
+import com.goafanti.common.dao.OutsourceLogMapper;
 import com.goafanti.common.dao.TArrearsDunMapper;
 import com.goafanti.common.dao.TDunLogMapper;
 import com.goafanti.common.dao.TOrderBackMapper;
@@ -65,6 +66,7 @@ import com.goafanti.common.model.NewOrderDun;
 import com.goafanti.common.model.Notice;
 import com.goafanti.common.model.OrganizationContactBook;
 import com.goafanti.common.model.OrganizationManagement;
+import com.goafanti.common.model.OutsourceLog;
 import com.goafanti.common.model.TArrearsDun;
 import com.goafanti.common.model.TDunLog;
 import com.goafanti.common.model.TOrderBack;
@@ -157,6 +159,8 @@ public class OrderNewServiceImpl extends BaseMybatisDao<TOrderNewMapper> impleme
 	private TOrderExtendMapper	tOrderExtendMapper;
 	@Autowired
 	private UserMapper	userMapper;
+	@Autowired
+	private OutsourceLogMapper	outsourceLogMapper;
 	@Value(value = "${mobileRemindCodeTemplate}")
 	private String					mobileRemindCodeTemplate	= null;
 	@Value(value = "${upload.path}")
@@ -1278,6 +1282,9 @@ public class OrderNewServiceImpl extends BaseMybatisDao<TOrderNewMapper> impleme
 				aids.add(admin.getId());
 			}
 			TOrderNew t2= checkDeleteSign(o.getOrderNo());
+			Admin a =adminMapper.selectByPrimaryKey(TokenManager.getAdminId());
+			OutsourceLog ol=new OutsourceLog(o.getTid(),0,o.getOutsourceRemarks(), TokenManager.getAdminId(),a.getName());
+			outsourceLogMapper.insertSelective(ol);
 			pushGeneralSendNoticeAndEmail(aids, NoticeStatus.PROJECT_OUTSOURCE_START.getCode(),o.getOrderNo(), TokenManager.getAdminId(),t2.getApproval());
 		}
 		if (o.getId()!=null) {

+ 19 - 0
src/main/java/com/goafanti/order/service/impl/OutsourceOrgServiceImpl.java

@@ -12,6 +12,7 @@ import org.springframework.stereotype.Service;
 
 import com.goafanti.common.dao.AdminMapper;
 import com.goafanti.common.dao.OrganizationManagementMapper;
+import com.goafanti.common.dao.OutsourceLogMapper;
 import com.goafanti.common.dao.OutsourceOrganizationMapper;
 import com.goafanti.common.dao.TOrderLogMapper;
 import com.goafanti.common.dao.TOrderNewMapper;
@@ -19,6 +20,8 @@ import com.goafanti.common.dao.TOrderOutsourceMapper;
 import com.goafanti.common.dao.TOrderTaskMapper;
 import com.goafanti.common.enums.NoticeStatus;
 import com.goafanti.common.enums.OrderLogProcess;
+import com.goafanti.common.model.Admin;
+import com.goafanti.common.model.OutsourceLog;
 import com.goafanti.common.model.OutsourceOrganization;
 import com.goafanti.common.model.TOrderLog;
 import com.goafanti.common.model.TOrderNew;
@@ -28,6 +31,7 @@ import com.goafanti.core.mybatis.page.Pagination;
 import com.goafanti.core.shiro.token.TokenManager;
 import com.goafanti.order.bo.OrderOutsourceBo;
 import com.goafanti.order.bo.OrderOutsourceDtails;
+import com.goafanti.order.bo.OutOutsourceLog;
 import com.goafanti.order.bo.OutsourceOrganizationBo;
 import com.goafanti.order.enums.ProcessStatus;
 import com.goafanti.order.service.OrderNewService;
@@ -54,6 +58,8 @@ public class OutsourceOrgServiceImpl  extends BaseMybatisDao<TOrderOutsourceMapp
 	private OrderNewService	orderNewService;
 	@Autowired
 	private AdminMapper	adminMapper;
+	@Autowired
+	private OutsourceLogMapper	outsourceLogMapper;
 	@Override
 	public int addOutsourceOrg(OutsourceOrganization o) {
 		return outsourceOrganizationMapper.insertSelective(o);
@@ -131,6 +137,12 @@ public class OutsourceOrgServiceImpl  extends BaseMybatisDao<TOrderOutsourceMapp
 		}else if (o.getType()==1) {//项目外包
 			TOrderTask tt=tOrderTaskMapper.selectByPrimaryKey(o.getTid());
 			aids.add(tt.getTaskReceiver());
+			Admin a =adminMapper.selectByPrimaryKey(TokenManager.getAdminId());
+			OutsourceLog ol=new OutsourceLog();
+			ol.setAid(TokenManager.getAdminId());
+			ol.setAname(a.getName());
+			ol.setRemarks(o.getRemarks());
+			ol.setTid(o.getTid());
 			if (o.getRefundStatus()==1) {
 				//把项目更改成外包项目
 				TOrderTask tt2=new TOrderTask();
@@ -138,11 +150,14 @@ public class OutsourceOrgServiceImpl  extends BaseMybatisDao<TOrderOutsourceMapp
 				tt2.setOutsource(1);
 				tOrderTaskMapper.updateByPrimaryKeySelective(tt2);
 				type=NoticeStatus.PROJECT_OUTSOURCE_YES.getCode();
+				ol.setStatus(1);
 				addOrderLog(o.getOrderNo(),OrderLogProcess.XMWBTG.getCode(),o.getRemarks());
 			}else {
 				type=NoticeStatus.PROJECT_OUTSOURCE_NO.getCode();
+				ol.setStatus(2);
 				addOrderLog(o.getOrderNo(),OrderLogProcess.XMWBBH.getCode(),o.getRemarks());
 			}
+			outsourceLogMapper.insertSelective(ol);
 		}
 		orderNewService.pushGeneralSendNoticeAndEmail(aids, type,o.getOrderNo(), TokenManager.getAdminId(),t2.getApproval());
 		return tOrderOutsourceMapper.updateByPrimaryKeySelective(o);
@@ -173,5 +188,9 @@ public class OutsourceOrgServiceImpl  extends BaseMybatisDao<TOrderOutsourceMapp
 		Pagination<OrderOutsourceBo> p = (Pagination<OrderOutsourceBo>)findPage("salesmanOrderOutsourceList", "salesmanOrderOutsourceCount", params, pageNo, pageSize);
 		return p;
 	}
+	@Override
+	public List<OutOutsourceLog> selectOutsourceLog(Integer tid) {
+		return outsourceLogMapper.selectByTid(tid);
+	}
 
 }