Sfoglia il codice sorgente

修改客户新增功能

wanghui 8 anni fa
parent
commit
22b026a06b

+ 1 - 1
generatorConfig.xml

@@ -8,6 +8,6 @@
     <javaModelGenerator targetPackage="com.goafanti.common.model" targetProject="AFT" />
     <sqlMapGenerator targetPackage="com.goafanti.common.mapper" targetProject="AFT" />
     <javaClientGenerator targetPackage="com.goafanti.common.dao" targetProject="AFT" type="XMLMAPPER" />
-    <table schema="aft" tableName="customer_log"/>
+    <table schema="aft" tableName="follow_up_record"/>
   </context>
 </generatorConfiguration>

+ 22 - 11
src/main/java/com/goafanti/common/dao/FollowUpRecordMapper.java

@@ -11,71 +11,82 @@ public interface FollowUpRecordMapper {
 
 	/**
 	 * This method was generated by MyBatis Generator. This method corresponds to the database table follow_up_record
-	 * @mbg.generated  Wed Oct 18 19:10:46 CST 2017
+	 * @mbg.generated  Wed Nov 01 21:31:29 CST 2017
 	 */
 	long countByExample(FollowUpRecordExample example);
 
+
 	/**
 	 * This method was generated by MyBatis Generator. This method corresponds to the database table follow_up_record
-	 * @mbg.generated  Wed Oct 18 19:10:46 CST 2017
+	 * @mbg.generated  Wed Nov 01 21:31:29 CST 2017
 	 */
 	int deleteByExample(FollowUpRecordExample example);
 
+
 	/**
 	 * This method was generated by MyBatis Generator. This method corresponds to the database table follow_up_record
-	 * @mbg.generated  Wed Oct 18 19:10:46 CST 2017
+	 * @mbg.generated  Wed Nov 01 21:31:29 CST 2017
 	 */
 	int deleteByPrimaryKey(String id);
 
+
 	/**
 	 * This method was generated by MyBatis Generator. This method corresponds to the database table follow_up_record
-	 * @mbg.generated  Wed Oct 18 19:10:46 CST 2017
+	 * @mbg.generated  Wed Nov 01 21:31:29 CST 2017
 	 */
 	int insert(FollowUpRecord record);
 
+
 	/**
 	 * This method was generated by MyBatis Generator. This method corresponds to the database table follow_up_record
-	 * @mbg.generated  Wed Oct 18 19:10:46 CST 2017
+	 * @mbg.generated  Wed Nov 01 21:31:29 CST 2017
 	 */
 	int insertSelective(FollowUpRecord record);
 
+
 	/**
 	 * This method was generated by MyBatis Generator. This method corresponds to the database table follow_up_record
-	 * @mbg.generated  Wed Oct 18 19:10:46 CST 2017
+	 * @mbg.generated  Wed Nov 01 21:31:29 CST 2017
 	 */
 	List<FollowUpRecord> selectByExample(FollowUpRecordExample example);
 
+
 	/**
 	 * This method was generated by MyBatis Generator. This method corresponds to the database table follow_up_record
-	 * @mbg.generated  Wed Oct 18 19:10:46 CST 2017
+	 * @mbg.generated  Wed Nov 01 21:31:29 CST 2017
 	 */
 	FollowUpRecord selectByPrimaryKey(String id);
 
+
 	/**
 	 * This method was generated by MyBatis Generator. This method corresponds to the database table follow_up_record
-	 * @mbg.generated  Wed Oct 18 19:10:46 CST 2017
+	 * @mbg.generated  Wed Nov 01 21:31:29 CST 2017
 	 */
 	int updateByExampleSelective(@Param("record") FollowUpRecord record,
 			@Param("example") FollowUpRecordExample example);
 
+
 	/**
 	 * This method was generated by MyBatis Generator. This method corresponds to the database table follow_up_record
-	 * @mbg.generated  Wed Oct 18 19:10:46 CST 2017
+	 * @mbg.generated  Wed Nov 01 21:31:29 CST 2017
 	 */
 	int updateByExample(@Param("record") FollowUpRecord record, @Param("example") FollowUpRecordExample example);
 
+
 	/**
 	 * This method was generated by MyBatis Generator. This method corresponds to the database table follow_up_record
-	 * @mbg.generated  Wed Oct 18 19:10:46 CST 2017
+	 * @mbg.generated  Wed Nov 01 21:31:29 CST 2017
 	 */
 	int updateByPrimaryKeySelective(FollowUpRecord record);
 
+
 	/**
 	 * This method was generated by MyBatis Generator. This method corresponds to the database table follow_up_record
-	 * @mbg.generated  Wed Oct 18 19:10:46 CST 2017
+	 * @mbg.generated  Wed Nov 01 21:31:29 CST 2017
 	 */
 	int updateByPrimaryKey(FollowUpRecord record);
 
+
 	/**
 	 * 查询跟进记录列表
 	 * @param customerId

+ 22 - 22
src/main/java/com/goafanti/common/mapper/FollowUpRecordMapper.xml

@@ -5,7 +5,7 @@
     <!--
       WARNING - @mbg.generated
       This element is automatically generated by MyBatis Generator, do not modify.
-      This element was generated on Wed Oct 18 19:10:46 CST 2017.
+      This element was generated on Wed Nov 01 21:31:29 CST 2017.
     -->
     <id column="id" jdbcType="VARCHAR" property="id" />
     <result column="cid" jdbcType="VARCHAR" property="cid" />
@@ -14,7 +14,7 @@
     <result column="tm_stamp" jdbcType="TIMESTAMP" property="tmStamp" />
     <result column="follow_result" jdbcType="VARCHAR" property="followResult" />
     <result column="follow_situation" jdbcType="INTEGER" property="followSituation" />
-    <result column="attachment" jdbcType="INTEGER" property="attachment" />
+    <result column="attachment" jdbcType="VARCHAR" property="attachment" />
     <result column="cuid" jdbcType="VARCHAR" property="cuid" />
     <result column="customer_status" jdbcType="INTEGER" property="customerStatus" />
     <result column="contact_info" jdbcType="VARCHAR" property="contactInfo" />
@@ -24,7 +24,7 @@
     <!--
       WARNING - @mbg.generated
       This element is automatically generated by MyBatis Generator, do not modify.
-      This element was generated on Wed Oct 18 19:10:46 CST 2017.
+      This element was generated on Wed Nov 01 21:31:29 CST 2017.
     -->
     <where>
       <foreach collection="oredCriteria" item="criteria" separator="or">
@@ -58,7 +58,7 @@
     <!--
       WARNING - @mbg.generated
       This element is automatically generated by MyBatis Generator, do not modify.
-      This element was generated on Wed Oct 18 19:10:46 CST 2017.
+      This element was generated on Wed Nov 01 21:31:29 CST 2017.
     -->
     <where>
       <foreach collection="example.oredCriteria" item="criteria" separator="or">
@@ -92,7 +92,7 @@
     <!--
       WARNING - @mbg.generated
       This element is automatically generated by MyBatis Generator, do not modify.
-      This element was generated on Wed Oct 18 19:10:46 CST 2017.
+      This element was generated on Wed Nov 01 21:31:29 CST 2017.
     -->
     id, cid, aid, follow_date, tm_stamp, follow_result, follow_situation, attachment, 
     cuid, customer_status, contact_info, effective
@@ -101,7 +101,7 @@
     <!--
       WARNING - @mbg.generated
       This element is automatically generated by MyBatis Generator, do not modify.
-      This element was generated on Wed Oct 18 19:10:46 CST 2017.
+      This element was generated on Wed Nov 01 21:31:29 CST 2017.
     -->
     select
     <if test="distinct">
@@ -120,7 +120,7 @@
     <!--
       WARNING - @mbg.generated
       This element is automatically generated by MyBatis Generator, do not modify.
-      This element was generated on Wed Oct 18 19:10:46 CST 2017.
+      This element was generated on Wed Nov 01 21:31:29 CST 2017.
     -->
     select 
     <include refid="Base_Column_List" />
@@ -131,7 +131,7 @@
     <!--
       WARNING - @mbg.generated
       This element is automatically generated by MyBatis Generator, do not modify.
-      This element was generated on Wed Oct 18 19:10:46 CST 2017.
+      This element was generated on Wed Nov 01 21:31:29 CST 2017.
     -->
     delete from follow_up_record
     where id = #{id,jdbcType=VARCHAR}
@@ -140,7 +140,7 @@
     <!--
       WARNING - @mbg.generated
       This element is automatically generated by MyBatis Generator, do not modify.
-      This element was generated on Wed Oct 18 19:10:46 CST 2017.
+      This element was generated on Wed Nov 01 21:31:29 CST 2017.
     -->
     delete from follow_up_record
     <if test="_parameter != null">
@@ -151,7 +151,7 @@
     <!--
       WARNING - @mbg.generated
       This element is automatically generated by MyBatis Generator, do not modify.
-      This element was generated on Wed Oct 18 19:10:46 CST 2017.
+      This element was generated on Wed Nov 01 21:31:29 CST 2017.
     -->
     insert into follow_up_record (id, cid, aid, 
       follow_date, tm_stamp, follow_result, 
@@ -160,7 +160,7 @@
       )
     values (#{id,jdbcType=VARCHAR}, #{cid,jdbcType=VARCHAR}, #{aid,jdbcType=VARCHAR}, 
       #{followDate,jdbcType=TIMESTAMP}, #{tmStamp,jdbcType=TIMESTAMP}, #{followResult,jdbcType=VARCHAR}, 
-      #{followSituation,jdbcType=INTEGER}, #{attachment,jdbcType=INTEGER}, #{cuid,jdbcType=VARCHAR}, 
+      #{followSituation,jdbcType=INTEGER}, #{attachment,jdbcType=VARCHAR}, #{cuid,jdbcType=VARCHAR}, 
       #{customerStatus,jdbcType=INTEGER}, #{contactInfo,jdbcType=VARCHAR}, #{effective,jdbcType=INTEGER}
       )
   </insert>
@@ -168,7 +168,7 @@
     <!--
       WARNING - @mbg.generated
       This element is automatically generated by MyBatis Generator, do not modify.
-      This element was generated on Wed Oct 18 19:10:46 CST 2017.
+      This element was generated on Wed Nov 01 21:31:29 CST 2017.
     -->
     insert into follow_up_record
     <trim prefix="(" suffix=")" suffixOverrides=",">
@@ -232,7 +232,7 @@
         #{followSituation,jdbcType=INTEGER},
       </if>
       <if test="attachment != null">
-        #{attachment,jdbcType=INTEGER},
+        #{attachment,jdbcType=VARCHAR},
       </if>
       <if test="cuid != null">
         #{cuid,jdbcType=VARCHAR},
@@ -252,7 +252,7 @@
     <!--
       WARNING - @mbg.generated
       This element is automatically generated by MyBatis Generator, do not modify.
-      This element was generated on Wed Oct 18 19:10:46 CST 2017.
+      This element was generated on Wed Nov 01 21:31:29 CST 2017.
     -->
     select count(*) from follow_up_record
     <if test="_parameter != null">
@@ -263,7 +263,7 @@
     <!--
       WARNING - @mbg.generated
       This element is automatically generated by MyBatis Generator, do not modify.
-      This element was generated on Wed Oct 18 19:10:46 CST 2017.
+      This element was generated on Wed Nov 01 21:31:29 CST 2017.
     -->
     update follow_up_record
     <set>
@@ -289,7 +289,7 @@
         follow_situation = #{record.followSituation,jdbcType=INTEGER},
       </if>
       <if test="record.attachment != null">
-        attachment = #{record.attachment,jdbcType=INTEGER},
+        attachment = #{record.attachment,jdbcType=VARCHAR},
       </if>
       <if test="record.cuid != null">
         cuid = #{record.cuid,jdbcType=VARCHAR},
@@ -312,7 +312,7 @@
     <!--
       WARNING - @mbg.generated
       This element is automatically generated by MyBatis Generator, do not modify.
-      This element was generated on Wed Oct 18 19:10:46 CST 2017.
+      This element was generated on Wed Nov 01 21:31:29 CST 2017.
     -->
     update follow_up_record
     set id = #{record.id,jdbcType=VARCHAR},
@@ -322,7 +322,7 @@
       tm_stamp = #{record.tmStamp,jdbcType=TIMESTAMP},
       follow_result = #{record.followResult,jdbcType=VARCHAR},
       follow_situation = #{record.followSituation,jdbcType=INTEGER},
-      attachment = #{record.attachment,jdbcType=INTEGER},
+      attachment = #{record.attachment,jdbcType=VARCHAR},
       cuid = #{record.cuid,jdbcType=VARCHAR},
       customer_status = #{record.customerStatus,jdbcType=INTEGER},
       contact_info = #{record.contactInfo,jdbcType=VARCHAR},
@@ -335,7 +335,7 @@
     <!--
       WARNING - @mbg.generated
       This element is automatically generated by MyBatis Generator, do not modify.
-      This element was generated on Wed Oct 18 19:10:46 CST 2017.
+      This element was generated on Wed Nov 01 21:31:29 CST 2017.
     -->
     update follow_up_record
     <set>
@@ -358,7 +358,7 @@
         follow_situation = #{followSituation,jdbcType=INTEGER},
       </if>
       <if test="attachment != null">
-        attachment = #{attachment,jdbcType=INTEGER},
+        attachment = #{attachment,jdbcType=VARCHAR},
       </if>
       <if test="cuid != null">
         cuid = #{cuid,jdbcType=VARCHAR},
@@ -379,7 +379,7 @@
     <!--
       WARNING - @mbg.generated
       This element is automatically generated by MyBatis Generator, do not modify.
-      This element was generated on Wed Oct 18 19:10:46 CST 2017.
+      This element was generated on Wed Nov 01 21:31:29 CST 2017.
     -->
     update follow_up_record
     set cid = #{cid,jdbcType=VARCHAR},
@@ -388,7 +388,7 @@
       tm_stamp = #{tmStamp,jdbcType=TIMESTAMP},
       follow_result = #{followResult,jdbcType=VARCHAR},
       follow_situation = #{followSituation,jdbcType=INTEGER},
-      attachment = #{attachment,jdbcType=INTEGER},
+      attachment = #{attachment,jdbcType=VARCHAR},
       cuid = #{cuid,jdbcType=VARCHAR},
       customer_status = #{customerStatus,jdbcType=INTEGER},
       contact_info = #{contactInfo,jdbcType=VARCHAR},

+ 39 - 39
src/main/java/com/goafanti/common/model/FollowUpRecord.java

@@ -6,69 +6,69 @@ public class FollowUpRecord {
 
 	/**
 	 * This field was generated by MyBatis Generator. This field corresponds to the database column follow_up_record.id
-	 * @mbg.generated  Wed Oct 18 19:10:46 CST 2017
+	 * @mbg.generated  Wed Nov 01 21:31:29 CST 2017
 	 */
 	private String id;
 	/**
 	 * This field was generated by MyBatis Generator. This field corresponds to the database column follow_up_record.cid
-	 * @mbg.generated  Wed Oct 18 19:10:46 CST 2017
+	 * @mbg.generated  Wed Nov 01 21:31:29 CST 2017
 	 */
 	private String cid;
 	/**
 	 * This field was generated by MyBatis Generator. This field corresponds to the database column follow_up_record.aid
-	 * @mbg.generated  Wed Oct 18 19:10:46 CST 2017
+	 * @mbg.generated  Wed Nov 01 21:31:29 CST 2017
 	 */
 	private String aid;
 	/**
 	 * This field was generated by MyBatis Generator. This field corresponds to the database column follow_up_record.follow_date
-	 * @mbg.generated  Wed Oct 18 19:10:46 CST 2017
+	 * @mbg.generated  Wed Nov 01 21:31:29 CST 2017
 	 */
 	private Date followDate;
 	/**
 	 * This field was generated by MyBatis Generator. This field corresponds to the database column follow_up_record.tm_stamp
-	 * @mbg.generated  Wed Oct 18 19:10:46 CST 2017
+	 * @mbg.generated  Wed Nov 01 21:31:29 CST 2017
 	 */
 	private Date tmStamp;
 	/**
 	 * This field was generated by MyBatis Generator. This field corresponds to the database column follow_up_record.follow_result
-	 * @mbg.generated  Wed Oct 18 19:10:46 CST 2017
+	 * @mbg.generated  Wed Nov 01 21:31:29 CST 2017
 	 */
 	private String followResult;
 	/**
 	 * This field was generated by MyBatis Generator. This field corresponds to the database column follow_up_record.follow_situation
-	 * @mbg.generated  Wed Oct 18 19:10:46 CST 2017
+	 * @mbg.generated  Wed Nov 01 21:31:29 CST 2017
 	 */
 	private Integer followSituation;
 	/**
 	 * This field was generated by MyBatis Generator. This field corresponds to the database column follow_up_record.attachment
-	 * @mbg.generated  Wed Oct 18 19:10:46 CST 2017
+	 * @mbg.generated  Wed Nov 01 21:31:29 CST 2017
 	 */
-	private Integer attachment;
+	private String attachment;
 	/**
 	 * This field was generated by MyBatis Generator. This field corresponds to the database column follow_up_record.cuid
-	 * @mbg.generated  Wed Oct 18 19:10:46 CST 2017
+	 * @mbg.generated  Wed Nov 01 21:31:29 CST 2017
 	 */
 	private String cuid;
 	/**
 	 * This field was generated by MyBatis Generator. This field corresponds to the database column follow_up_record.customer_status
-	 * @mbg.generated  Wed Oct 18 19:10:46 CST 2017
+	 * @mbg.generated  Wed Nov 01 21:31:29 CST 2017
 	 */
 	private Integer customerStatus;
 	/**
 	 * This field was generated by MyBatis Generator. This field corresponds to the database column follow_up_record.contact_info
-	 * @mbg.generated  Wed Oct 18 19:10:46 CST 2017
+	 * @mbg.generated  Wed Nov 01 21:31:29 CST 2017
 	 */
 	private String contactInfo;
 	/**
 	 * This field was generated by MyBatis Generator. This field corresponds to the database column follow_up_record.effective
-	 * @mbg.generated  Wed Oct 18 19:10:46 CST 2017
+	 * @mbg.generated  Wed Nov 01 21:31:29 CST 2017
 	 */
 	private Integer effective;
 
 	/**
 	 * This method was generated by MyBatis Generator. This method returns the value of the database column follow_up_record.id
 	 * @return  the value of follow_up_record.id
-	 * @mbg.generated  Wed Oct 18 19:10:46 CST 2017
+	 * @mbg.generated  Wed Nov 01 21:31:29 CST 2017
 	 */
 	public String getId() {
 		return id;
@@ -77,7 +77,7 @@ public class FollowUpRecord {
 	/**
 	 * This method was generated by MyBatis Generator. This method sets the value of the database column follow_up_record.id
 	 * @param id  the value for follow_up_record.id
-	 * @mbg.generated  Wed Oct 18 19:10:46 CST 2017
+	 * @mbg.generated  Wed Nov 01 21:31:29 CST 2017
 	 */
 	public void setId(String id) {
 		this.id = id;
@@ -86,7 +86,7 @@ public class FollowUpRecord {
 	/**
 	 * This method was generated by MyBatis Generator. This method returns the value of the database column follow_up_record.cid
 	 * @return  the value of follow_up_record.cid
-	 * @mbg.generated  Wed Oct 18 19:10:46 CST 2017
+	 * @mbg.generated  Wed Nov 01 21:31:29 CST 2017
 	 */
 	public String getCid() {
 		return cid;
@@ -95,7 +95,7 @@ public class FollowUpRecord {
 	/**
 	 * This method was generated by MyBatis Generator. This method sets the value of the database column follow_up_record.cid
 	 * @param cid  the value for follow_up_record.cid
-	 * @mbg.generated  Wed Oct 18 19:10:46 CST 2017
+	 * @mbg.generated  Wed Nov 01 21:31:29 CST 2017
 	 */
 	public void setCid(String cid) {
 		this.cid = cid;
@@ -104,7 +104,7 @@ public class FollowUpRecord {
 	/**
 	 * This method was generated by MyBatis Generator. This method returns the value of the database column follow_up_record.aid
 	 * @return  the value of follow_up_record.aid
-	 * @mbg.generated  Wed Oct 18 19:10:46 CST 2017
+	 * @mbg.generated  Wed Nov 01 21:31:29 CST 2017
 	 */
 	public String getAid() {
 		return aid;
@@ -113,7 +113,7 @@ public class FollowUpRecord {
 	/**
 	 * This method was generated by MyBatis Generator. This method sets the value of the database column follow_up_record.aid
 	 * @param aid  the value for follow_up_record.aid
-	 * @mbg.generated  Wed Oct 18 19:10:46 CST 2017
+	 * @mbg.generated  Wed Nov 01 21:31:29 CST 2017
 	 */
 	public void setAid(String aid) {
 		this.aid = aid;
@@ -122,7 +122,7 @@ public class FollowUpRecord {
 	/**
 	 * This method was generated by MyBatis Generator. This method returns the value of the database column follow_up_record.follow_date
 	 * @return  the value of follow_up_record.follow_date
-	 * @mbg.generated  Wed Oct 18 19:10:46 CST 2017
+	 * @mbg.generated  Wed Nov 01 21:31:29 CST 2017
 	 */
 	public Date getFollowDate() {
 		return followDate;
@@ -131,7 +131,7 @@ public class FollowUpRecord {
 	/**
 	 * This method was generated by MyBatis Generator. This method sets the value of the database column follow_up_record.follow_date
 	 * @param followDate  the value for follow_up_record.follow_date
-	 * @mbg.generated  Wed Oct 18 19:10:46 CST 2017
+	 * @mbg.generated  Wed Nov 01 21:31:29 CST 2017
 	 */
 	public void setFollowDate(Date followDate) {
 		this.followDate = followDate;
@@ -140,7 +140,7 @@ public class FollowUpRecord {
 	/**
 	 * This method was generated by MyBatis Generator. This method returns the value of the database column follow_up_record.tm_stamp
 	 * @return  the value of follow_up_record.tm_stamp
-	 * @mbg.generated  Wed Oct 18 19:10:46 CST 2017
+	 * @mbg.generated  Wed Nov 01 21:31:29 CST 2017
 	 */
 	public Date getTmStamp() {
 		return tmStamp;
@@ -149,7 +149,7 @@ public class FollowUpRecord {
 	/**
 	 * This method was generated by MyBatis Generator. This method sets the value of the database column follow_up_record.tm_stamp
 	 * @param tmStamp  the value for follow_up_record.tm_stamp
-	 * @mbg.generated  Wed Oct 18 19:10:46 CST 2017
+	 * @mbg.generated  Wed Nov 01 21:31:29 CST 2017
 	 */
 	public void setTmStamp(Date tmStamp) {
 		this.tmStamp = tmStamp;
@@ -158,7 +158,7 @@ public class FollowUpRecord {
 	/**
 	 * This method was generated by MyBatis Generator. This method returns the value of the database column follow_up_record.follow_result
 	 * @return  the value of follow_up_record.follow_result
-	 * @mbg.generated  Wed Oct 18 19:10:46 CST 2017
+	 * @mbg.generated  Wed Nov 01 21:31:29 CST 2017
 	 */
 	public String getFollowResult() {
 		return followResult;
@@ -167,7 +167,7 @@ public class FollowUpRecord {
 	/**
 	 * This method was generated by MyBatis Generator. This method sets the value of the database column follow_up_record.follow_result
 	 * @param followResult  the value for follow_up_record.follow_result
-	 * @mbg.generated  Wed Oct 18 19:10:46 CST 2017
+	 * @mbg.generated  Wed Nov 01 21:31:29 CST 2017
 	 */
 	public void setFollowResult(String followResult) {
 		this.followResult = followResult;
@@ -176,7 +176,7 @@ public class FollowUpRecord {
 	/**
 	 * This method was generated by MyBatis Generator. This method returns the value of the database column follow_up_record.follow_situation
 	 * @return  the value of follow_up_record.follow_situation
-	 * @mbg.generated  Wed Oct 18 19:10:46 CST 2017
+	 * @mbg.generated  Wed Nov 01 21:31:29 CST 2017
 	 */
 	public Integer getFollowSituation() {
 		return followSituation;
@@ -185,7 +185,7 @@ public class FollowUpRecord {
 	/**
 	 * This method was generated by MyBatis Generator. This method sets the value of the database column follow_up_record.follow_situation
 	 * @param followSituation  the value for follow_up_record.follow_situation
-	 * @mbg.generated  Wed Oct 18 19:10:46 CST 2017
+	 * @mbg.generated  Wed Nov 01 21:31:29 CST 2017
 	 */
 	public void setFollowSituation(Integer followSituation) {
 		this.followSituation = followSituation;
@@ -194,25 +194,25 @@ public class FollowUpRecord {
 	/**
 	 * This method was generated by MyBatis Generator. This method returns the value of the database column follow_up_record.attachment
 	 * @return  the value of follow_up_record.attachment
-	 * @mbg.generated  Wed Oct 18 19:10:46 CST 2017
+	 * @mbg.generated  Wed Nov 01 21:31:29 CST 2017
 	 */
-	public Integer getAttachment() {
+	public String getAttachment() {
 		return attachment;
 	}
 
 	/**
 	 * This method was generated by MyBatis Generator. This method sets the value of the database column follow_up_record.attachment
 	 * @param attachment  the value for follow_up_record.attachment
-	 * @mbg.generated  Wed Oct 18 19:10:46 CST 2017
+	 * @mbg.generated  Wed Nov 01 21:31:29 CST 2017
 	 */
-	public void setAttachment(Integer attachment) {
+	public void setAttachment(String attachment) {
 		this.attachment = attachment;
 	}
 
 	/**
 	 * This method was generated by MyBatis Generator. This method returns the value of the database column follow_up_record.cuid
 	 * @return  the value of follow_up_record.cuid
-	 * @mbg.generated  Wed Oct 18 19:10:46 CST 2017
+	 * @mbg.generated  Wed Nov 01 21:31:29 CST 2017
 	 */
 	public String getCuid() {
 		return cuid;
@@ -221,7 +221,7 @@ public class FollowUpRecord {
 	/**
 	 * This method was generated by MyBatis Generator. This method sets the value of the database column follow_up_record.cuid
 	 * @param cuid  the value for follow_up_record.cuid
-	 * @mbg.generated  Wed Oct 18 19:10:46 CST 2017
+	 * @mbg.generated  Wed Nov 01 21:31:29 CST 2017
 	 */
 	public void setCuid(String cuid) {
 		this.cuid = cuid;
@@ -230,7 +230,7 @@ public class FollowUpRecord {
 	/**
 	 * This method was generated by MyBatis Generator. This method returns the value of the database column follow_up_record.customer_status
 	 * @return  the value of follow_up_record.customer_status
-	 * @mbg.generated  Wed Oct 18 19:10:46 CST 2017
+	 * @mbg.generated  Wed Nov 01 21:31:29 CST 2017
 	 */
 	public Integer getCustomerStatus() {
 		return customerStatus;
@@ -239,7 +239,7 @@ public class FollowUpRecord {
 	/**
 	 * This method was generated by MyBatis Generator. This method sets the value of the database column follow_up_record.customer_status
 	 * @param customerStatus  the value for follow_up_record.customer_status
-	 * @mbg.generated  Wed Oct 18 19:10:46 CST 2017
+	 * @mbg.generated  Wed Nov 01 21:31:29 CST 2017
 	 */
 	public void setCustomerStatus(Integer customerStatus) {
 		this.customerStatus = customerStatus;
@@ -248,7 +248,7 @@ public class FollowUpRecord {
 	/**
 	 * This method was generated by MyBatis Generator. This method returns the value of the database column follow_up_record.contact_info
 	 * @return  the value of follow_up_record.contact_info
-	 * @mbg.generated  Wed Oct 18 19:10:46 CST 2017
+	 * @mbg.generated  Wed Nov 01 21:31:29 CST 2017
 	 */
 	public String getContactInfo() {
 		return contactInfo;
@@ -257,7 +257,7 @@ public class FollowUpRecord {
 	/**
 	 * This method was generated by MyBatis Generator. This method sets the value of the database column follow_up_record.contact_info
 	 * @param contactInfo  the value for follow_up_record.contact_info
-	 * @mbg.generated  Wed Oct 18 19:10:46 CST 2017
+	 * @mbg.generated  Wed Nov 01 21:31:29 CST 2017
 	 */
 	public void setContactInfo(String contactInfo) {
 		this.contactInfo = contactInfo;
@@ -266,7 +266,7 @@ public class FollowUpRecord {
 	/**
 	 * This method was generated by MyBatis Generator. This method returns the value of the database column follow_up_record.effective
 	 * @return  the value of follow_up_record.effective
-	 * @mbg.generated  Wed Oct 18 19:10:46 CST 2017
+	 * @mbg.generated  Wed Nov 01 21:31:29 CST 2017
 	 */
 	public Integer getEffective() {
 		return effective;
@@ -275,7 +275,7 @@ public class FollowUpRecord {
 	/**
 	 * This method was generated by MyBatis Generator. This method sets the value of the database column follow_up_record.effective
 	 * @param effective  the value for follow_up_record.effective
-	 * @mbg.generated  Wed Oct 18 19:10:46 CST 2017
+	 * @mbg.generated  Wed Nov 01 21:31:29 CST 2017
 	 */
 	public void setEffective(Integer effective) {
 		this.effective = effective;

+ 36 - 26
src/main/java/com/goafanti/common/model/FollowUpRecordExample.java

@@ -7,23 +7,23 @@ import java.util.List;
 public class FollowUpRecordExample {
     /**
 	 * This field was generated by MyBatis Generator. This field corresponds to the database table follow_up_record
-	 * @mbg.generated  Wed Oct 18 19:10:46 CST 2017
+	 * @mbg.generated  Wed Nov 01 21:31:29 CST 2017
 	 */
 	protected String orderByClause;
 	/**
 	 * This field was generated by MyBatis Generator. This field corresponds to the database table follow_up_record
-	 * @mbg.generated  Wed Oct 18 19:10:46 CST 2017
+	 * @mbg.generated  Wed Nov 01 21:31:29 CST 2017
 	 */
 	protected boolean distinct;
 	/**
 	 * This field was generated by MyBatis Generator. This field corresponds to the database table follow_up_record
-	 * @mbg.generated  Wed Oct 18 19:10:46 CST 2017
+	 * @mbg.generated  Wed Nov 01 21:31:29 CST 2017
 	 */
 	protected List<Criteria> oredCriteria;
 
 	/**
 	 * This method was generated by MyBatis Generator. This method corresponds to the database table follow_up_record
-	 * @mbg.generated  Wed Oct 18 19:10:46 CST 2017
+	 * @mbg.generated  Wed Nov 01 21:31:29 CST 2017
 	 */
 	public FollowUpRecordExample() {
 		oredCriteria = new ArrayList<Criteria>();
@@ -31,7 +31,7 @@ public class FollowUpRecordExample {
 
 	/**
 	 * This method was generated by MyBatis Generator. This method corresponds to the database table follow_up_record
-	 * @mbg.generated  Wed Oct 18 19:10:46 CST 2017
+	 * @mbg.generated  Wed Nov 01 21:31:29 CST 2017
 	 */
 	public void setOrderByClause(String orderByClause) {
 		this.orderByClause = orderByClause;
@@ -39,7 +39,7 @@ public class FollowUpRecordExample {
 
 	/**
 	 * This method was generated by MyBatis Generator. This method corresponds to the database table follow_up_record
-	 * @mbg.generated  Wed Oct 18 19:10:46 CST 2017
+	 * @mbg.generated  Wed Nov 01 21:31:29 CST 2017
 	 */
 	public String getOrderByClause() {
 		return orderByClause;
@@ -47,7 +47,7 @@ public class FollowUpRecordExample {
 
 	/**
 	 * This method was generated by MyBatis Generator. This method corresponds to the database table follow_up_record
-	 * @mbg.generated  Wed Oct 18 19:10:46 CST 2017
+	 * @mbg.generated  Wed Nov 01 21:31:29 CST 2017
 	 */
 	public void setDistinct(boolean distinct) {
 		this.distinct = distinct;
@@ -55,7 +55,7 @@ public class FollowUpRecordExample {
 
 	/**
 	 * This method was generated by MyBatis Generator. This method corresponds to the database table follow_up_record
-	 * @mbg.generated  Wed Oct 18 19:10:46 CST 2017
+	 * @mbg.generated  Wed Nov 01 21:31:29 CST 2017
 	 */
 	public boolean isDistinct() {
 		return distinct;
@@ -63,7 +63,7 @@ public class FollowUpRecordExample {
 
 	/**
 	 * This method was generated by MyBatis Generator. This method corresponds to the database table follow_up_record
-	 * @mbg.generated  Wed Oct 18 19:10:46 CST 2017
+	 * @mbg.generated  Wed Nov 01 21:31:29 CST 2017
 	 */
 	public List<Criteria> getOredCriteria() {
 		return oredCriteria;
@@ -71,7 +71,7 @@ public class FollowUpRecordExample {
 
 	/**
 	 * This method was generated by MyBatis Generator. This method corresponds to the database table follow_up_record
-	 * @mbg.generated  Wed Oct 18 19:10:46 CST 2017
+	 * @mbg.generated  Wed Nov 01 21:31:29 CST 2017
 	 */
 	public void or(Criteria criteria) {
 		oredCriteria.add(criteria);
@@ -79,7 +79,7 @@ public class FollowUpRecordExample {
 
 	/**
 	 * This method was generated by MyBatis Generator. This method corresponds to the database table follow_up_record
-	 * @mbg.generated  Wed Oct 18 19:10:46 CST 2017
+	 * @mbg.generated  Wed Nov 01 21:31:29 CST 2017
 	 */
 	public Criteria or() {
 		Criteria criteria = createCriteriaInternal();
@@ -89,7 +89,7 @@ public class FollowUpRecordExample {
 
 	/**
 	 * This method was generated by MyBatis Generator. This method corresponds to the database table follow_up_record
-	 * @mbg.generated  Wed Oct 18 19:10:46 CST 2017
+	 * @mbg.generated  Wed Nov 01 21:31:29 CST 2017
 	 */
 	public Criteria createCriteria() {
 		Criteria criteria = createCriteriaInternal();
@@ -101,7 +101,7 @@ public class FollowUpRecordExample {
 
 	/**
 	 * This method was generated by MyBatis Generator. This method corresponds to the database table follow_up_record
-	 * @mbg.generated  Wed Oct 18 19:10:46 CST 2017
+	 * @mbg.generated  Wed Nov 01 21:31:29 CST 2017
 	 */
 	protected Criteria createCriteriaInternal() {
 		Criteria criteria = new Criteria();
@@ -110,7 +110,7 @@ public class FollowUpRecordExample {
 
 	/**
 	 * This method was generated by MyBatis Generator. This method corresponds to the database table follow_up_record
-	 * @mbg.generated  Wed Oct 18 19:10:46 CST 2017
+	 * @mbg.generated  Wed Nov 01 21:31:29 CST 2017
 	 */
 	public void clear() {
 		oredCriteria.clear();
@@ -120,7 +120,7 @@ public class FollowUpRecordExample {
 
 	/**
 	 * This class was generated by MyBatis Generator. This class corresponds to the database table follow_up_record
-	 * @mbg.generated  Wed Oct 18 19:10:46 CST 2017
+	 * @mbg.generated  Wed Nov 01 21:31:29 CST 2017
 	 */
 	protected abstract static class GeneratedCriteria {
 		protected List<Criterion> criteria;
@@ -633,52 +633,62 @@ public class FollowUpRecordExample {
 			return (Criteria) this;
 		}
 
-		public Criteria andAttachmentEqualTo(Integer value) {
+		public Criteria andAttachmentEqualTo(String value) {
 			addCriterion("attachment =", value, "attachment");
 			return (Criteria) this;
 		}
 
-		public Criteria andAttachmentNotEqualTo(Integer value) {
+		public Criteria andAttachmentNotEqualTo(String value) {
 			addCriterion("attachment <>", value, "attachment");
 			return (Criteria) this;
 		}
 
-		public Criteria andAttachmentGreaterThan(Integer value) {
+		public Criteria andAttachmentGreaterThan(String value) {
 			addCriterion("attachment >", value, "attachment");
 			return (Criteria) this;
 		}
 
-		public Criteria andAttachmentGreaterThanOrEqualTo(Integer value) {
+		public Criteria andAttachmentGreaterThanOrEqualTo(String value) {
 			addCriterion("attachment >=", value, "attachment");
 			return (Criteria) this;
 		}
 
-		public Criteria andAttachmentLessThan(Integer value) {
+		public Criteria andAttachmentLessThan(String value) {
 			addCriterion("attachment <", value, "attachment");
 			return (Criteria) this;
 		}
 
-		public Criteria andAttachmentLessThanOrEqualTo(Integer value) {
+		public Criteria andAttachmentLessThanOrEqualTo(String value) {
 			addCriterion("attachment <=", value, "attachment");
 			return (Criteria) this;
 		}
 
-		public Criteria andAttachmentIn(List<Integer> values) {
+		public Criteria andAttachmentLike(String value) {
+			addCriterion("attachment like", value, "attachment");
+			return (Criteria) this;
+		}
+
+		public Criteria andAttachmentNotLike(String value) {
+			addCriterion("attachment not like", value, "attachment");
+			return (Criteria) this;
+		}
+
+		public Criteria andAttachmentIn(List<String> values) {
 			addCriterion("attachment in", values, "attachment");
 			return (Criteria) this;
 		}
 
-		public Criteria andAttachmentNotIn(List<Integer> values) {
+		public Criteria andAttachmentNotIn(List<String> values) {
 			addCriterion("attachment not in", values, "attachment");
 			return (Criteria) this;
 		}
 
-		public Criteria andAttachmentBetween(Integer value1, Integer value2) {
+		public Criteria andAttachmentBetween(String value1, String value2) {
 			addCriterion("attachment between", value1, value2, "attachment");
 			return (Criteria) this;
 		}
 
-		public Criteria andAttachmentNotBetween(Integer value1, Integer value2) {
+		public Criteria andAttachmentNotBetween(String value1, String value2) {
 			addCriterion("attachment not between", value1, value2, "attachment");
 			return (Criteria) this;
 		}
@@ -946,7 +956,7 @@ public class FollowUpRecordExample {
 
 	/**
 	 * This class was generated by MyBatis Generator. This class corresponds to the database table follow_up_record
-	 * @mbg.generated  Wed Oct 18 19:10:46 CST 2017
+	 * @mbg.generated  Wed Nov 01 21:31:29 CST 2017
 	 */
 	public static class Criterion {
 		private String condition;

+ 4 - 3
src/main/java/com/goafanti/customer/controller/AdminCustomerApiController.java

@@ -68,7 +68,7 @@ public class AdminCustomerApiController extends BaseApiController {
 		if(StringUtils.isEmpty(cusIn.getCompanyIntention())) res.getError().add(new Error("意向服务不能为空"));
 		if(StringUtils.isEmpty(cusIn.getFollowSituation())) res.getError().add(new Error("跟进进度不能为空"));
 		if(StringUtils.isEmpty(cusIn.getCustomerStatus())) res.getError().add(new Error("客户状态不能为空"));
-		if(StringUtils.isEmpty(cusIn.getContactName())) res.getError().add(new Error("联系人姓名不能"));
+		if(StringUtils.isEmpty(cui.getName())) res.getError().add(new Error("联系人姓名不能为空"));
 		if(StringUtils.isEmpty(cui.getMobile())&&StringUtils.isEmpty(cui.getTelNum())) res.getError().add(new Error("手机号码和座机不能同时为空"));
 		if(customerOrganizationService.findCustomerOrganizationByName(cusIn.getCompanyName())>0){
 			res.getError().add(buildError(ErrorConstants.CUSTOMER_ALREADY_EXIST));
@@ -85,7 +85,7 @@ public class AdminCustomerApiController extends BaseApiController {
 		cus.setFollowId(followId);
 		cus.setShareType(Integer.parseInt(cusIn.getShareType()));
 		cus.setCustomerType(Integer.parseInt(cusIn.getCustomerType()));
-		cus.setId(customerId);
+		cus.setAid(TokenManager.getAdminId());
 		cus.setCreateTime(new Date());
 		//公司信息和联系人信息表
 		cui.setId(customerUserId);
@@ -97,7 +97,8 @@ public class AdminCustomerApiController extends BaseApiController {
 		fur.setFollowDate(format.parse(cusIn.getFollowDates()));
 		fur.setId(followId);//跟进记录的ID
 		fur.setCid(customerId);//跟进记录表中的cid
-		fur.setCuid(customerUserId);//跟进记录表中的联系人id	
+		fur.setCuid(customerUserId);//跟进记录表中的联系人id
+		fur.setAid(TokenManager.getAdminId());
 		customerService.addCustomer(cus,cui,coi,fur);
 		//添加日志
 		cusIn.setId(customerId);

+ 14 - 11
src/main/java/com/goafanti/customer/service/impl/CustomerServiceImpl.java

@@ -60,7 +60,6 @@ public class CustomerServiceImpl extends BaseMybatisDao<CustomerMapper> implemen
 		followUpRecordMapper.insert(fur);
 		String paid = findLadderIds(TokenManager.getAdminId());//查询上级管理员ID集合
 		if(StringUtils.isNotBlank(paid)) paid = paid.substring(0, paid.length()-1);	
-		cus.setAid(TokenManager.getAdminId());
 		cus.setPaid(paid);
 		int res = customerMapper.insert(cus);
 		return res;
@@ -176,7 +175,7 @@ public class CustomerServiceImpl extends BaseMybatisDao<CustomerMapper> implemen
 	private CustomerOut setFiled(CustomerOut co) {
 		switch(co.getCustomerType()){
 			case 0 : co.set_customerType("个人客户") ;break;
-			case 1 : co.set_customerType("公司客户") ;break;
+			case 1 : co.set_customerType("机构单位") ;break;
 			case 2 : co.set_customerType("团体单位") ;break;
 		}
 		switch(co.getCustomerStatus()){
@@ -251,14 +250,14 @@ public class CustomerServiceImpl extends BaseMybatisDao<CustomerMapper> implemen
 	@Override
 	public void saveCustomerLog(CustomerIn cus,String operatorType){
 		/* 记录日志 */
-		String cid =cus.getId();
+		String cid = cus.getId();
 		CustomerLog log = new CustomerLog();
 		log.setId(UUID.randomUUID().toString());
 		log.setCid(cid);
 		log.setOperatorTime(new SimpleDateFormat(AFTConstants.YYYYMMDDHHMMSS).format(new Date()));
 		log.setOperatorName(TokenManager.getAdminToken().getName());
 		Customer c =  customerMapper.selectByPrimaryKey(cid) ;
-		String beforeAdminName = adminMapper.selectByPrimaryKey(c.getAid()).getName();
+		
 		if(operatorType.equals(AFTConstants.CUSTOMER_CREATE)){//创建用户
 			log.setAfterFollowSituation(CustomerFollowFiled.getField(Integer.parseInt(cus.getFollowSituation())).getDesc()); //跟进状态
 			log.setAfterCustomerIntention(getCompanyIntention(cus.getCompanyIntention())); //跟进意向
@@ -266,6 +265,7 @@ public class CustomerServiceImpl extends BaseMybatisDao<CustomerMapper> implemen
 			log.setAfterAdminName(TokenManager.getAdminToken().getName());
 			log.setOperatorType(AFTConstants.CUSTOMER_CREATE);
 		}else if(operatorType.equals(AFTConstants.CUSTOMER_MODIFY)){ //修改客户
+			String beforeAdminName = adminMapper.selectByPrimaryKey(c.getAid()).getName();
 			log.setBeforeAdminName(beforeAdminName);//修改前操作人
 			log.setBeforeCustomerIntention(getCompanyIntention(c.getCompanyIntention())); //修改前跟进意向
 			log.setBeforeCustomerStatus(CustomerStatusFiled.getField(c.getCustomerStatus()).getDesc()); //修改前跟进状态
@@ -276,19 +276,21 @@ public class CustomerServiceImpl extends BaseMybatisDao<CustomerMapper> implemen
 			log.setAfterCustomerStatus(CustomerStatusFiled.getField(Integer.parseInt(cus.getCustomerStatus())).getDesc()); //修改后客户状态
 			log.setOperatorType(AFTConstants.CUSTOMER_MODIFY);
 		}else if(operatorType.equals(AFTConstants.CUSTOMER_DELETE)){ //删除客户
+			String beforeAdminName = adminMapper.selectByPrimaryKey(c.getAid()).getName();
 			log.setBeforeAdminName(beforeAdminName); //删除前跟进人
-			log.setBeforeCustomerIntention(getCompanyIntention(cus.getBeforeCompanyIntention())); //跟进意向
-			log.setBeforeCustomerStatus(CustomerStatusFiled.getField(Integer.parseInt(cus.getBeforeCustomerStatus())).getDesc()); //跟进状态
-			log.setBeforeFollowSituation(CustomerFollowFiled.getField(Integer.parseInt(cus.getBeforeFollowSituation())).getDesc());//跟进进度
+			log.setBeforeCustomerIntention(getCompanyIntention(c.getCompanyIntention())); //删除前跟进意向
+			log.setBeforeCustomerStatus(CustomerStatusFiled.getField(c.getCustomerStatus()).getDesc()); //删除前跟进状态
+			log.setBeforeFollowSituation(CustomerFollowFiled.getField(c.getFollowSituation()).getDesc());//删除前跟进进度
 			log.setOperatorType(AFTConstants.CUSTOMER_DELETE);
 		}else if(operatorType.equals(AFTConstants.CUSTOMER_TRANSFER)){ //转交客户
 			log.setBeforeAdminName(cus.getBeforeAdminName());//转交前的人
 			log.setAfterAdminName(cus.getAdminName());//转交后的人
-			log.setBeforeCustomerIntention(getCompanyIntention(c.getCompanyIntention())); //修改前跟进意向
-			log.setBeforeCustomerStatus(CustomerStatusFiled.getField(c.getCustomerStatus()).getDesc()); //修改前跟进状态
-			log.setBeforeFollowSituation(CustomerFollowFiled.getField(c.getFollowSituation()).getDesc());//修改前跟进进度
+			log.setBeforeCustomerIntention(getCompanyIntention(c.getCompanyIntention())); //转交前跟进意向
+			log.setBeforeCustomerStatus(CustomerStatusFiled.getField(c.getCustomerStatus()).getDesc()); //转交前跟进状态
+			log.setBeforeFollowSituation(CustomerFollowFiled.getField(c.getFollowSituation()).getDesc());//转交前跟进进度
 			log.setOperatorType(AFTConstants.CUSTOMER_TRANSFER);
 		}else if(operatorType.equals(AFTConstants.CUSTOMER_RECEIVE)){ //领取客户
+			String beforeAdminName = adminMapper.selectByPrimaryKey(c.getAid()).getName();
 			log.setBeforeAdminName(beforeAdminName);//领取前的人
 			log.setAfterAdminName(TokenManager.getAdminToken().getName());//领取后跟进人
 			log.setBeforeCustomerIntention(getCompanyIntention(c.getCompanyIntention())); //领取前跟进意向
@@ -296,12 +298,13 @@ public class CustomerServiceImpl extends BaseMybatisDao<CustomerMapper> implemen
 			log.setBeforeFollowSituation(CustomerFollowFiled.getField(c.getFollowSituation()).getDesc());//领取前跟进进度
 			log.setOperatorType(AFTConstants.CUSTOMER_RECEIVE);
 		}else if(operatorType.equals(AFTConstants.CUSTOMER_TO_PUBLIC)){ //转为公共客户
-			log.setBeforeAdminName(beforeAdminName);//转为公共客户前跟进人
+			log.setBeforeAdminName(cus.getBeforeAdminName());//转为公共客户前跟进人
 			log.setBeforeCustomerIntention(getCompanyIntention(c.getCompanyIntention())); //转换前跟进意向
 			log.setBeforeCustomerStatus(CustomerStatusFiled.getField(c.getCustomerStatus()).getDesc()); //转换前跟进状态
 			log.setBeforeFollowSituation(CustomerFollowFiled.getField(c.getFollowSituation()).getDesc());//转换前跟进进度
 			log.setOperatorType(AFTConstants.CUSTOMER_TO_PUBLIC);
 		}else if(operatorType.equals(AFTConstants.CUSTOMER_FOLLOW)){ //跟进客户
+			String beforeAdminName = adminMapper.selectByPrimaryKey(c.getAid()).getName();
 			log.setBeforeAdminName(beforeAdminName);//跟进前操作人
 			log.setBeforeCustomerIntention(getCompanyIntention(c.getCompanyIntention())); //修改前跟进意向
 			log.setBeforeCustomerStatus(CustomerStatusFiled.getField(c.getCustomerStatus()).getDesc()); //修改前跟进状态

+ 1 - 1
src/main/resources/props/config_local.properties

@@ -54,7 +54,7 @@ session.validate.timespan=18000000
 app.name=AFT
 template.cacheable=false
 
-static.host=//sb.jishutao.com/1.0.47
+static.host=//sb.jishutao.com/1.0.48
 portal.host=//sf.jishutao.com/portal/2.0.6
 avatar.host=//sb.jishutao.com
 avatar.upload.host=//sb.jishutao.com/upload