ソースを参照

修改跟进接口

anderx 1 年間 前
コミット
76d3670366

+ 6 - 39
src/main/java/com/goafanti/common/dao/UserFollowMapper.java

@@ -6,51 +6,18 @@ import org.apache.ibatis.annotations.Param;
 import java.util.List;
 
 public interface UserFollowMapper {
-    /**
-     * This method was generated by MyBatis Generator.
-     * This method corresponds to the database table user_follow
-     *
-     * @mbggenerated
-     */
-    int deleteByPrimaryKey(String id);
-
-    /**
-     * This method was generated by MyBatis Generator.
-     * This method corresponds to the database table user_follow
-     *
-     * @mbggenerated
-     */
+
+    int deleteByPrimaryKey(Long id);
+
     int insert(UserFollow record);
 
-    /**
-     * This method was generated by MyBatis Generator.
-     * This method corresponds to the database table user_follow
-     *
-     * @mbggenerated
-     */
     int insertSelective(UserFollow record);
 
-    /**
-     * This method was generated by MyBatis Generator.
-     * This method corresponds to the database table user_follow
-     *
-     * @mbggenerated
-     */
-    UserFollow selectByPrimaryKey(String id);
-
-    /**
-     * This method was generated by MyBatis Generator.
-     * This method corresponds to the database table user_follow
-     *
-     * @mbggenerated
-     */
+    UserFollow selectByPrimaryKey(Long id);
+
     int updateByPrimaryKeySelective(UserFollow record);
 
-	/**
-	 * This method was generated by MyBatis Generator. This method corresponds to the database table user_follow
-	 * @mbg.generated  Sat Oct 10 10:18:15 CST 2020
-	 */
-	int updateByPrimaryKey(UserFollow record);
+    int updateByPrimaryKey(UserFollow record);
 
 
 	int pushUserGuidance(@Param("id")String id, @Param("guidance")Integer guidance);

+ 317 - 374
src/main/java/com/goafanti/common/mapper/UserFollowMapper.xml

@@ -1,387 +1,330 @@
 <?xml version="1.0" encoding="UTF-8"?>
-<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
+<!DOCTYPE mapper
+        PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN"
+        "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
 <mapper namespace="com.goafanti.common.dao.UserFollowMapper">
-  <resultMap id="BaseResultMap" type="com.goafanti.common.model.UserFollow">
-    <!--
-      WARNING - @mbg.generated
-      This element is automatically generated by MyBatis Generator, do not modify.
-    -->
-    <id column="id" jdbcType="VARCHAR" property="id" />
-    <result column="uid" jdbcType="VARCHAR" property="uid" />
-    <result column="aid" jdbcType="VARCHAR" property="aid" />
-    <result column="paid" jdbcType="VARCHAR" property="paid" />
-    <result column="result" jdbcType="VARCHAR" property="result" />
-    <result column="attachment_url" jdbcType="VARCHAR" property="attachmentUrl" />
-    <result column="create_time" jdbcType="TIMESTAMP" property="createTime" />
-    <result column="ocb_id" jdbcType="VARCHAR" property="ocbId" />
-    <result column="contact_type" jdbcType="INTEGER" property="contactType" />
-    <result column="effective" jdbcType="INTEGER" property="effective" />
-    <result column="time_stamp" jdbcType="TIMESTAMP" property="timeStamp" />
-    <result column="follow_count" jdbcType="INTEGER" property="followCount" />
-    <result column="guidance" jdbcType="VARCHAR" property="guidance" />
-    <result column="guidance_time" jdbcType="TIMESTAMP" property="guidanceTime" />
-    <result column="guidance_aid" jdbcType="VARCHAR" property="guidanceAid" />
-    <result column="guidance_name" jdbcType="VARCHAR" property="guidanceName" />
-  </resultMap>
-  <sql id="Base_Column_List">
-    <!--
-      WARNING - @mbg.generated
-      This element is automatically generated by MyBatis Generator, do not modify.
-    -->
-    id, `uid`, aid, paid, `result`, attachment_url, create_time, ocb_id, contact_type,
-    effective, time_stamp, follow_count, guidance, guidance_time, guidance_aid, guidance_name
-  </sql>
-  <select id="selectByPrimaryKey" parameterType="java.lang.String" resultMap="BaseResultMap">
-    <!--
-      WARNING - @mbg.generated
-      This element is automatically generated by MyBatis Generator, do not modify.
-    -->
-    select
-    <include refid="Base_Column_List" />
-    from user_follow
-    where id = #{id,jdbcType=VARCHAR}
-  </select>
-  <delete id="deleteByPrimaryKey" parameterType="java.lang.String">
-    <!--
-      WARNING - @mbg.generated
-      This element is automatically generated by MyBatis Generator, do not modify.
-    -->
-    delete from user_follow
-    where id = #{id,jdbcType=VARCHAR}
-  </delete>
-  <insert id="insert" parameterType="com.goafanti.common.model.UserFollow">
-    <!--
-      WARNING - @mbg.generated
-      This element is automatically generated by MyBatis Generator, do not modify.
-    -->
-    insert into user_follow (id, `uid`, aid,
-      paid, `result`, attachment_url,
-      create_time, ocb_id, contact_type,
-      effective, time_stamp, follow_count,
-      guidance, guidance_time, guidance_aid,
-      guidance_name,follow_name,follow_dep)
-    values (#{id,jdbcType=VARCHAR}, #{uid,jdbcType=VARCHAR}, #{aid,jdbcType=VARCHAR},
-      #{paid,jdbcType=VARCHAR}, #{result,jdbcType=VARCHAR}, #{attachmentUrl,jdbcType=VARCHAR},
-      #{createTime,jdbcType=TIMESTAMP}, #{ocbId,jdbcType=VARCHAR}, #{contactType,jdbcType=INTEGER},
-      #{effective,jdbcType=INTEGER}, #{timeStamp,jdbcType=TIMESTAMP}, #{followCount,jdbcType=INTEGER},
-      #{guidance,jdbcType=VARCHAR}, #{guidanceTime,jdbcType=TIMESTAMP}, #{guidanceAid,jdbcType=VARCHAR},
-      #{guidanceName,jdbcType=VARCHAR},#{followName},#{followDep})
-  </insert>
-  <insert id="insertSelective" parameterType="com.goafanti.common.model.UserFollow">
-    <!--
-      WARNING - @mbg.generated
-      This element is automatically generated by MyBatis Generator, do not modify.
-    -->
-    insert into user_follow
-    <trim prefix="(" suffix=")" suffixOverrides=",">
-      <if test="id != null">
-        id,
-      </if>
-      <if test="uid != null">
-        `uid`,
-      </if>
-      <if test="aid != null">
-        aid,
-      </if>
-      <if test="paid != null">
-        paid,
-      </if>
-      <if test="result != null">
-        `result`,
-      </if>
-      <if test="attachmentUrl != null">
-        attachment_url,
-      </if>
-      <if test="createTime != null">
-        create_time,
-      </if>
-      <if test="ocbId != null">
-        ocb_id,
-      </if>
-      <if test="contactType != null">
-        contact_type,
-      </if>
-      <if test="effective != null">
-        effective,
-      </if>
-      <if test="timeStamp != null">
-        time_stamp,
-      </if>
-      <if test="followCount != null">
-        follow_count,
-      </if>
-      <if test="guidance != null">
-        guidance,
-      </if>
-      <if test="guidanceTime != null">
-        guidance_time,
-      </if>
-      <if test="guidanceAid != null">
-        guidance_aid,
-      </if>
-      <if test="guidanceName != null">
-        guidance_name,
-      </if>
-    </trim>
-    <trim prefix="values (" suffix=")" suffixOverrides=",">
-      <if test="id != null">
-        #{id,jdbcType=VARCHAR},
-      </if>
-      <if test="uid != null">
-        #{uid,jdbcType=VARCHAR},
-      </if>
-      <if test="aid != null">
-        #{aid,jdbcType=VARCHAR},
-      </if>
-      <if test="paid != null">
-        #{paid,jdbcType=VARCHAR},
-      </if>
-      <if test="result != null">
-        #{result,jdbcType=VARCHAR},
-      </if>
-      <if test="attachmentUrl != null">
-        #{attachmentUrl,jdbcType=VARCHAR},
-      </if>
-      <if test="createTime != null">
-        #{createTime,jdbcType=TIMESTAMP},
-      </if>
-      <if test="ocbId != null">
-        #{ocbId,jdbcType=VARCHAR},
-      </if>
-      <if test="contactType != null">
-        #{contactType,jdbcType=INTEGER},
-      </if>
-      <if test="effective != null">
-        #{effective,jdbcType=INTEGER},
-      </if>
-      <if test="timeStamp != null">
-        #{timeStamp,jdbcType=TIMESTAMP},
-      </if>
-      <if test="followCount != null">
-        #{followCount,jdbcType=INTEGER},
-      </if>
-      <if test="guidance != null">
-        #{guidance,jdbcType=VARCHAR},
-      </if>
-      <if test="guidanceTime != null">
-        #{guidanceTime,jdbcType=TIMESTAMP},
-      </if>
-      <if test="guidanceAid != null">
-        #{guidanceAid,jdbcType=VARCHAR},
-      </if>
-      <if test="guidanceName != null">
-        #{guidanceName,jdbcType=VARCHAR},
-      </if>
-    </trim>
-  </insert>
-  <update id="updateByPrimaryKeySelective" parameterType="com.goafanti.common.model.UserFollow">
-    <!--
-      WARNING - @mbg.generated
-      This element is automatically generated by MyBatis Generator, do not modify.
-    -->
-    update user_follow
-    <set>
-      <if test="uid != null">
-        `uid` = #{uid,jdbcType=VARCHAR},
-      </if>
-      <if test="aid != null">
-        aid = #{aid,jdbcType=VARCHAR},
-      </if>
-      <if test="paid != null">
-        paid = #{paid,jdbcType=VARCHAR},
-      </if>
-      <if test="result != null">
-        `result` = #{result,jdbcType=VARCHAR},
-      </if>
-      <if test="attachmentUrl != null">
-        attachment_url = #{attachmentUrl,jdbcType=VARCHAR},
-      </if>
-      <if test="createTime != null">
-        create_time = #{createTime,jdbcType=TIMESTAMP},
-      </if>
-      <if test="ocbId != null">
-        ocb_id = #{ocbId,jdbcType=VARCHAR},
-      </if>
-      <if test="contactType != null">
-        contact_type = #{contactType,jdbcType=INTEGER},
-      </if>
-      <if test="effective != null">
-        effective = #{effective,jdbcType=INTEGER},
-      </if>
-      <if test="timeStamp != null">
-        time_stamp = #{timeStamp,jdbcType=TIMESTAMP},
-      </if>
-      <if test="followCount != null">
-        follow_count = #{followCount,jdbcType=INTEGER},
-      </if>
-      <if test="guidance != null">
-        guidance = #{guidance,jdbcType=VARCHAR},
-      </if>
-      <if test="guidanceTime != null">
-        guidance_time = #{guidanceTime,jdbcType=TIMESTAMP},
-      </if>
-      <if test="guidanceAid != null">
-        guidance_aid = #{guidanceAid,jdbcType=VARCHAR},
-      </if>
-      <if test="guidanceName != null">
-        guidance_name = #{guidanceName,jdbcType=VARCHAR},
-      </if>
-    </set>
-    where id = #{id,jdbcType=VARCHAR}
-  </update>
-  <update id="updateByPrimaryKey" parameterType="com.goafanti.common.model.UserFollow">
-    <!--
-      WARNING - @mbg.generated
-      This element is automatically generated by MyBatis Generator, do not modify.
-    -->
-    update user_follow
-    set `uid` = #{uid,jdbcType=VARCHAR},
-      aid = #{aid,jdbcType=VARCHAR},
-      paid = #{paid,jdbcType=VARCHAR},
-      `result` = #{result,jdbcType=VARCHAR},
-      attachment_url = #{attachmentUrl,jdbcType=VARCHAR},
-      create_time = #{createTime,jdbcType=TIMESTAMP},
-      ocb_id = #{ocbId,jdbcType=VARCHAR},
-      contact_type = #{contactType,jdbcType=INTEGER},
-      effective = #{effective,jdbcType=INTEGER},
-      time_stamp = #{timeStamp,jdbcType=TIMESTAMP},
-      follow_count = #{followCount,jdbcType=INTEGER},
-      guidance = #{guidance,jdbcType=VARCHAR},
-      guidance_time = #{guidanceTime,jdbcType=TIMESTAMP},
-      guidance_aid = #{guidanceAid,jdbcType=VARCHAR},
-      guidance_name = #{guidanceName,jdbcType=VARCHAR}
-    where id = #{id,jdbcType=VARCHAR}
-  </update>
-	<update id="pushUserGuidance">
-		update user_follow b, `user` a
-		set a.guidance= #{guidance}
-		where a.id=b.uid and b.id= #{id}
-	</update>
-	<select id="selectbyUid" resultMap="BaseResultMap">
 
-		select
-		<include refid="Base_Column_List" />
-		from user_follow a
-		where a.uid= #{uid}
-		and a.aid= #{aid}
-	</select>
+    <resultMap id="BaseResultMap" type="com.goafanti.common.model.UserFollow">
+            <id property="id" column="id" jdbcType="VARCHAR"/>
+            <result property="uid" column="uid" jdbcType="VARCHAR"/>
+            <result property="aid" column="aid" jdbcType="VARCHAR"/>
+            <result property="paid" column="paid" jdbcType="VARCHAR"/>
+            <result property="result" column="result" jdbcType="VARCHAR"/>
+            <result property="attachmentUrl" column="attachment_url" jdbcType="VARCHAR"/>
+            <result property="createTime" column="create_time" jdbcType="TIMESTAMP"/>
+            <result property="ocbId" column="ocb_id" jdbcType="VARCHAR"/>
+            <result property="contactType" column="contact_type" jdbcType="INTEGER"/>
+            <result property="effective" column="effective" jdbcType="INTEGER"/>
+            <result property="timeStamp" column="time_stamp" jdbcType="TIMESTAMP"/>
+            <result property="followCount" column="follow_count" jdbcType="INTEGER"/>
+            <result property="guidance" column="guidance" jdbcType="VARCHAR"/>
+            <result property="guidanceTime" column="guidance_time" jdbcType="TIMESTAMP"/>
+            <result property="guidanceAid" column="guidance_aid" jdbcType="VARCHAR"/>
+            <result property="guidanceName" column="guidance_name" jdbcType="VARCHAR"/>
+            <result property="followName" column="follow_name" jdbcType="VARCHAR"/>
+            <result property="followDep" column="follow_dep" jdbcType="VARCHAR"/>
+            <result property="type" column="type" jdbcType="INTEGER"/>
+    </resultMap>
 
+    <sql id="Base_Column_List">
+        id,uid,aid,
+        paid,result,attachment_url,
+        create_time,ocb_id,contact_type,
+        effective,time_stamp,follow_count,
+        guidance,guidance_time,guidance_aid,
+        guidance_name,follow_name,follow_dep,
+        type
+    </sql>
 
-	<select id="userFollowList" resultType="com.goafanti.user.bo.outUserFollowList">
-      select b.nickname,b.share_type shareType ,b.channel,b.id,date_format(b.transfer_time,'%Y-%m-%d %H:%i:%s')startTimes,
-      a.contact_type contactType,a.follow_name followName ,a.follow_dep followDep,a.`result` ,a.follow_count followCount,
-      date_format(a.create_time ,'%Y-%m-%d %H:%i:%s')followTimes,a.guidance_name guidanceName, a.guidance ,
-      date_format(a.guidance_time,'%Y-%m-%d %H:%i:%s') guidanceTimes,c.contacts ,c.contact_mobile contactMobile,
-      c.location_province province ,c.location_city city ,c.location_area area,
-      c.intended_project intendedProject ,c.business_scope businessScope
-      from user_follow a left join `user`b on a.uid =b.id left join organization_identity c on a.uid=c.uid
-      left join admin d on a.aid =d.id
-      where 1=1
-      <if test="shiroType == 0">
-      and a.aid= #{aid}
-      </if>
-      <if test="shiroType == 1">
-        and a.aid in
-        <foreach close=")" collection="aids" item="id" open="(" separator=",">
-          #{id}
-        </foreach>
-      </if>
-      <if test="followName != null">
-        and a.follow_name  like concat('%',#{followName},'%')
-      </if>
-      <if test="userName != null">
-		  and b.nickname like concat('%',#{userName},'%')
-		</if>
-		<if test="userType == 1">
-		  and b.share_type =0
-		</if>
-		<if test="userType == 2">
-		  and b.share_type =1
-		</if>
-      <if test="userType == 3">
-        and b.share_type =2
-      </if>
-      <if test="userType == 4">
-        and b.share_type =3
-      </if>
-		<if test="contactType != null">
-			and a.contact_type = #{contactType}
-		</if>
-		<if test="followStartTime !=null and followEndTime !=null">
-		    and a.create_time between #{followStartTime} and #{followEndTime}
+    <select id="selectByPrimaryKey" parameterType="java.lang.Long" resultMap="BaseResultMap">
+        select
+        <include refid="Base_Column_List" />
+        from user_follow
+        where  id = #{id,jdbcType=VARCHAR} 
+    </select>
+
+    <delete id="deleteByPrimaryKey" parameterType="java.lang.Long">
+        delete from user_follow
+        where  id = #{id,jdbcType=VARCHAR} 
+    </delete>
+    <insert id="insert" keyColumn="id" keyProperty="id" parameterType="com.goafanti.common.model.UserFollow" useGeneratedKeys="true">
+        insert into user_follow
+        ( id,uid,aid
+        ,paid,result,attachment_url
+        ,create_time,ocb_id,contact_type
+        ,effective,time_stamp,follow_count
+        ,guidance,guidance_time,guidance_aid
+        ,guidance_name,follow_name,follow_dep
+        ,type)
+        values (#{id,jdbcType=VARCHAR},#{uid,jdbcType=VARCHAR},#{aid,jdbcType=VARCHAR}
+        ,#{paid,jdbcType=VARCHAR},#{result,jdbcType=VARCHAR},#{attachmentUrl,jdbcType=VARCHAR}
+        ,#{createTime,jdbcType=TIMESTAMP},#{ocbId,jdbcType=VARCHAR},#{contactType,jdbcType=INTEGER}
+        ,#{effective,jdbcType=INTEGER},#{timeStamp,jdbcType=TIMESTAMP},#{followCount,jdbcType=INTEGER}
+        ,#{guidance,jdbcType=VARCHAR},#{guidanceTime,jdbcType=TIMESTAMP},#{guidanceAid,jdbcType=VARCHAR}
+        ,#{guidanceName,jdbcType=VARCHAR},#{followName,jdbcType=VARCHAR},#{followDep,jdbcType=VARCHAR}
+        ,#{type,jdbcType=INTEGER})
+    </insert>
+    <insert id="insertSelective" keyColumn="id" keyProperty="id" parameterType="com.goafanti.common.model.UserFollow" useGeneratedKeys="true">
+        insert into user_follow
+        <trim prefix="(" suffix=")" suffixOverrides=",">
+                <if test="id != null">id,</if>
+                <if test="uid != null">uid,</if>
+                <if test="aid != null">aid,</if>
+                <if test="paid != null">paid,</if>
+                <if test="result != null">result,</if>
+                <if test="attachmentUrl != null">attachment_url,</if>
+                <if test="createTime != null">create_time,</if>
+                <if test="ocbId != null">ocb_id,</if>
+                <if test="contactType != null">contact_type,</if>
+                <if test="effective != null">effective,</if>
+                <if test="timeStamp != null">time_stamp,</if>
+                <if test="followCount != null">follow_count,</if>
+                <if test="guidance != null">guidance,</if>
+                <if test="guidanceTime != null">guidance_time,</if>
+                <if test="guidanceAid != null">guidance_aid,</if>
+                <if test="guidanceName != null">guidance_name,</if>
+                <if test="followName != null">follow_name,</if>
+                <if test="followDep != null">follow_dep,</if>
+                <if test="type != null">type,</if>
+        </trim>
+        <trim prefix="values (" suffix=")" suffixOverrides=",">
+                <if test="id != null">#{id,jdbcType=VARCHAR},</if>
+                <if test="uid != null">#{uid,jdbcType=VARCHAR},</if>
+                <if test="aid != null">#{aid,jdbcType=VARCHAR},</if>
+                <if test="paid != null">#{paid,jdbcType=VARCHAR},</if>
+                <if test="result != null">#{result,jdbcType=VARCHAR},</if>
+                <if test="attachmentUrl != null">#{attachmentUrl,jdbcType=VARCHAR},</if>
+                <if test="createTime != null">#{createTime,jdbcType=TIMESTAMP},</if>
+                <if test="ocbId != null">#{ocbId,jdbcType=VARCHAR},</if>
+                <if test="contactType != null">#{contactType,jdbcType=INTEGER},</if>
+                <if test="effective != null">#{effective,jdbcType=INTEGER},</if>
+                <if test="timeStamp != null">#{timeStamp,jdbcType=TIMESTAMP},</if>
+                <if test="followCount != null">#{followCount,jdbcType=INTEGER},</if>
+                <if test="guidance != null">#{guidance,jdbcType=VARCHAR},</if>
+                <if test="guidanceTime != null">#{guidanceTime,jdbcType=TIMESTAMP},</if>
+                <if test="guidanceAid != null">#{guidanceAid,jdbcType=VARCHAR},</if>
+                <if test="guidanceName != null">#{guidanceName,jdbcType=VARCHAR},</if>
+                <if test="followName != null">#{followName,jdbcType=VARCHAR},</if>
+                <if test="followDep != null">#{followDep,jdbcType=VARCHAR},</if>
+                <if test="type != null">#{type,jdbcType=INTEGER},</if>
+        </trim>
+    </insert>
+    <update id="updateByPrimaryKeySelective" parameterType="com.goafanti.common.model.UserFollow">
+        update user_follow
+        <set>
+                <if test="uid != null">
+                    uid = #{uid,jdbcType=VARCHAR},
+                </if>
+                <if test="aid != null">
+                    aid = #{aid,jdbcType=VARCHAR},
+                </if>
+                <if test="paid != null">
+                    paid = #{paid,jdbcType=VARCHAR},
+                </if>
+                <if test="result != null">
+                    result = #{result,jdbcType=VARCHAR},
+                </if>
+                <if test="attachmentUrl != null">
+                    attachment_url = #{attachmentUrl,jdbcType=VARCHAR},
+                </if>
+                <if test="createTime != null">
+                    create_time = #{createTime,jdbcType=TIMESTAMP},
+                </if>
+                <if test="ocbId != null">
+                    ocb_id = #{ocbId,jdbcType=VARCHAR},
+                </if>
+                <if test="contactType != null">
+                    contact_type = #{contactType,jdbcType=INTEGER},
+                </if>
+                <if test="effective != null">
+                    effective = #{effective,jdbcType=INTEGER},
+                </if>
+                <if test="timeStamp != null">
+                    time_stamp = #{timeStamp,jdbcType=TIMESTAMP},
+                </if>
+                <if test="followCount != null">
+                    follow_count = #{followCount,jdbcType=INTEGER},
+                </if>
+                <if test="guidance != null">
+                    guidance = #{guidance,jdbcType=VARCHAR},
+                </if>
+                <if test="guidanceTime != null">
+                    guidance_time = #{guidanceTime,jdbcType=TIMESTAMP},
+                </if>
+                <if test="guidanceAid != null">
+                    guidance_aid = #{guidanceAid,jdbcType=VARCHAR},
+                </if>
+                <if test="guidanceName != null">
+                    guidance_name = #{guidanceName,jdbcType=VARCHAR},
+                </if>
+                <if test="followName != null">
+                    follow_name = #{followName,jdbcType=VARCHAR},
+                </if>
+                <if test="followDep != null">
+                    follow_dep = #{followDep,jdbcType=VARCHAR},
+                </if>
+                <if test="type != null">
+                    type = #{type,jdbcType=INTEGER},
+                </if>
+        </set>
+        where   id = #{id,jdbcType=VARCHAR} 
+    </update>
+    <update id="updateByPrimaryKey" parameterType="com.goafanti.common.model.UserFollow">
+        update user_follow
+        set 
+            uid =  #{uid,jdbcType=VARCHAR},
+            aid =  #{aid,jdbcType=VARCHAR},
+            paid =  #{paid,jdbcType=VARCHAR},
+            result =  #{result,jdbcType=VARCHAR},
+            attachment_url =  #{attachmentUrl,jdbcType=VARCHAR},
+            create_time =  #{createTime,jdbcType=TIMESTAMP},
+            ocb_id =  #{ocbId,jdbcType=VARCHAR},
+            contact_type =  #{contactType,jdbcType=INTEGER},
+            effective =  #{effective,jdbcType=INTEGER},
+            time_stamp =  #{timeStamp,jdbcType=TIMESTAMP},
+            follow_count =  #{followCount,jdbcType=INTEGER},
+            guidance =  #{guidance,jdbcType=VARCHAR},
+            guidance_time =  #{guidanceTime,jdbcType=TIMESTAMP},
+            guidance_aid =  #{guidanceAid,jdbcType=VARCHAR},
+            guidance_name =  #{guidanceName,jdbcType=VARCHAR},
+            follow_name =  #{followName,jdbcType=VARCHAR},
+            follow_dep =  #{followDep,jdbcType=VARCHAR},
+            type =  #{type,jdbcType=INTEGER}
+        where   id = #{id,jdbcType=VARCHAR} 
+    </update>
+
+
+    <update id="pushUserGuidance">
+        update user_follow b, `user` a
+        set a.guidance= #{guidance}
+        where a.id=b.uid and b.id= #{id}
+    </update>
+    <select id="selectbyUid" resultMap="BaseResultMap">
+
+        select
+        <include refid="Base_Column_List" />
+        from user_follow a
+        where a.uid= #{uid}
+        and a.aid= #{aid}
+    </select>
+
+
+    <select id="userFollowList" resultType="com.goafanti.user.bo.outUserFollowList">
+        select b.nickname,b.share_type shareType ,b.channel,b.id,date_format(b.transfer_time,'%Y-%m-%d %H:%i:%s')startTimes,
+        a.contact_type contactType,a.follow_name followName ,a.follow_dep followDep,a.`result` ,a.follow_count followCount,
+        date_format(a.create_time ,'%Y-%m-%d %H:%i:%s')followTimes,a.guidance_name guidanceName, a.guidance ,
+        date_format(a.guidance_time,'%Y-%m-%d %H:%i:%s') guidanceTimes,c.contacts ,c.contact_mobile contactMobile,
+        c.location_province province ,c.location_city city ,c.location_area area,
+        c.intended_project intendedProject ,c.business_scope businessScope
+        from user_follow a left join `user`b on a.uid =b.id left join organization_identity c on a.uid=c.uid
+        left join admin d on a.aid =d.id
+        where 1=1
+        <if test="shiroType == 0">
+            and a.aid= #{aid}
+        </if>
+        <if test="shiroType == 1">
+            and a.aid in
+            <foreach close=")" collection="aids" item="id" open="(" separator=",">
+                #{id}
+            </foreach>
+        </if>
+        <if test="followName != null">
+            and a.follow_name  like concat('%',#{followName},'%')
+        </if>
+        <if test="userName != null">
+            and b.nickname like concat('%',#{userName},'%')
+        </if>
+        <if test="userType == 1">
+            and b.share_type =0
+        </if>
+        <if test="userType == 2">
+            and b.share_type =1
+        </if>
+        <if test="userType == 3">
+            and b.share_type =2
+        </if>
+        <if test="userType == 4">
+            and b.share_type =3
+        </if>
+        <if test="contactType != null">
+            and a.contact_type = #{contactType}
+        </if>
+        <if test="followStartTime !=null and followEndTime !=null">
+            and a.create_time between #{followStartTime} and #{followEndTime}
         </if>
         <if test="createStartTime !=null and createEndTime !=null">
-		and b.transfer_time between #{createStartTime} and #{createEndTime}
-		</if>
+            and b.transfer_time between #{createStartTime} and #{createEndTime}
+        </if>
         <if test="guidanceStartTime !=null and guidanceEndTime !=null">
-		and a.guidance_time between #{guidanceStartTime} and #{guidanceEndTime}
-		</if>
+            and a.guidance_time between #{guidanceStartTime} and #{guidanceEndTime}
+        </if>
         <if test="deps != null">
-          and d.department_id in
-          <foreach close=")" collection="deps" item="depId" open="(" separator=",">
-            #{depId}
-          </foreach>
+            and d.department_id in
+            <foreach close=")" collection="deps" item="depId" open="(" separator=",">
+                #{depId}
+            </foreach>
         </if>
-		order by  a.create_time desc
-		<if test="page_sql != null">
-			${page_sql}
-		</if>
-	</select>
-	<select id="userFollowCount" resultType="java.lang.Integer">
-		select count(*)
-      from user_follow a left join `user`b on a.uid =b.id
-      left join admin d on a.aid =d.id where 1=1
-      <if test="shiroType == 0">
-        and a.aid= #{aid}
-      </if>
-      <if test="shiroType == 1">
-        and a.aid in
-        <foreach close=")" collection="aids" item="id" open="(" separator=",">
-          #{id}
-        </foreach>
-      </if>
-      <if test="followName != null">
-        and a.follow_name  like concat('%',#{followName},'%')
-      </if>
-      <if test="userName != null">
-        and b.nickname like concat('%',#{userName},'%')
-      </if>
-      <if test="userType == 1">
-        and b.share_type =0
-      </if>
-      <if test="userType == 2">
-        and b.share_type =1
-      </if>
-      <if test="userType == 3">
-        and b.share_type =2
-      </if>
-      <if test="userType == 4">
-        and b.share_type =3
-      </if>
-      <if test="contactType != null">
-        and a.contact_type = #{contactType}
-      </if>
-      <if test="followStartTime !=null and followEndTime !=null">
-        and a.create_time between #{followStartTime} and #{followEndTime}
-      </if>
-      <if test="createStartTime !=null and createEndTime !=null">
-        and b.transfer_time between #{createStartTime} and #{createEndTime}
-      </if>
-      <if test="guidanceStartTime !=null and guidanceEndTime !=null">
-        and a.guidance_time between #{guidanceStartTime} and #{guidanceEndTime}
-      </if>
-      <if test="deps != null">
-        and d.department_id in
-        <foreach close=")" collection="deps" item="depId" open="(" separator=",">
-          #{depId}
-        </foreach>
-      </if>
-	</select>
+        order by  a.create_time desc
+        <if test="page_sql != null">
+            ${page_sql}
+        </if>
+    </select>
+    <select id="userFollowCount" resultType="java.lang.Integer">
+        select count(*)
+        from user_follow a left join `user`b on a.uid =b.id
+        left join admin d on a.aid =d.id where 1=1
+        <if test="shiroType == 0">
+            and a.aid= #{aid}
+        </if>
+        <if test="shiroType == 1">
+            and a.aid in
+            <foreach close=")" collection="aids" item="id" open="(" separator=",">
+                #{id}
+            </foreach>
+        </if>
+        <if test="followName != null">
+            and a.follow_name  like concat('%',#{followName},'%')
+        </if>
+        <if test="userName != null">
+            and b.nickname like concat('%',#{userName},'%')
+        </if>
+        <if test="userType == 1">
+            and b.share_type =0
+        </if>
+        <if test="userType == 2">
+            and b.share_type =1
+        </if>
+        <if test="userType == 3">
+            and b.share_type =2
+        </if>
+        <if test="userType == 4">
+            and b.share_type =3
+        </if>
+        <if test="contactType != null">
+            and a.contact_type = #{contactType}
+        </if>
+        <if test="followStartTime !=null and followEndTime !=null">
+            and a.create_time between #{followStartTime} and #{followEndTime}
+        </if>
+        <if test="createStartTime !=null and createEndTime !=null">
+            and b.transfer_time between #{createStartTime} and #{createEndTime}
+        </if>
+        <if test="guidanceStartTime !=null and guidanceEndTime !=null">
+            and a.guidance_time between #{guidanceStartTime} and #{guidanceEndTime}
+        </if>
+        <if test="deps != null">
+            and d.department_id in
+            <foreach close=")" collection="deps" item="depId" open="(" separator=",">
+                #{depId}
+            </foreach>
+        </if>
+    </select>
     <select id="selectByaidAndDate" resultType="java.lang.Integer">
-      select count(*)followCount
-      from (select aid
-        from user_follow where aid= #{aid}
-        and create_time BETWEEN #{startTime} and #{endTime})a
-      group by aid
+        select count(*)followCount
+        from (select aid
+              from user_follow where aid= #{aid}
+                                 and create_time BETWEEN #{startTime} and #{endTime})a
+        group by aid
     </select>
 </mapper>
+

+ 112 - 369
src/main/java/com/goafanti/common/model/UserFollow.java

@@ -4,627 +4,370 @@ import java.io.Serializable;
 import java.util.Date;
 
 /**
- *
- * This class was generated by MyBatis Generator.
- * This class corresponds to the database table user_follow
+ * 客户跟进表
+ * @TableName user_follow
  */
 public class UserFollow implements Serializable {
     /**
-     *
-     * This field was generated by MyBatis Generator.
-     * This field corresponds to the database column user_follow.id
-     *
-     * @mbg.generated
+     * 
      */
     private String id;
 
     /**
-     * Database Column Remarks:
-     *   客户ID
-     *
-     * This field was generated by MyBatis Generator.
-     * This field corresponds to the database column user_follow.uid
-     *
-     * @mbg.generated
+     * 客户ID
      */
     private String uid;
 
     /**
-     * Database Column Remarks:
-     *   营销员ID
-     *
-     * This field was generated by MyBatis Generator.
-     * This field corresponds to the database column user_follow.aid
-     *
-     * @mbg.generated
+     * 营销员ID
      */
     private String aid;
 
     /**
-     * Database Column Remarks:
-     *   营销员上级集合
-     *
-     * This field was generated by MyBatis Generator.
-     * This field corresponds to the database column user_follow.paid
-     *
-     * @mbg.generated
+     * 营销员上级集合
      */
     private String paid;
 
     /**
-     * Database Column Remarks:
-     *   跟进结果
-     *
-     * This field was generated by MyBatis Generator.
-     * This field corresponds to the database column user_follow.result
-     *
-     * @mbg.generated
+     * 跟进结果
      */
     private String result;
 
     /**
-     * Database Column Remarks:
-     *   附件地址
-     *
-     * This field was generated by MyBatis Generator.
-     * This field corresponds to the database column user_follow.attachment_url
-     *
-     * @mbg.generated
+     * 附件地址
      */
     private String attachmentUrl;
 
     /**
-     * Database Column Remarks:
-     *   跟进时间
-     *
-     * This field was generated by MyBatis Generator.
-     * This field corresponds to the database column user_follow.create_time
-     *
-     * @mbg.generated
+     * 跟进时间
      */
     private Date createTime;
 
     /**
-     * Database Column Remarks:
-     *   企业联系人ID
-     *
-     * This field was generated by MyBatis Generator.
-     * This field corresponds to the database column user_follow.ocb_id
-     *
-     * @mbg.generated
+     * 企业联系人ID
      */
     private String ocbId;
 
     /**
-     * Database Column Remarks:
-     *   联系方式1.电话 2.QQ 3.微信 0外出
-     *
-     * This field was generated by MyBatis Generator.
-     * This field corresponds to the database column user_follow.contact_type
-     *
-     * @mbg.generated
+     * 联系方式 0外出 1.电话 2.QQ 3.微信  4邮件 5公出打卡
      */
     private Integer contactType;
 
     /**
-     * Database Column Remarks:
-     *   生效标示 0-有效 1-失效
-     *
-     * This field was generated by MyBatis Generator.
-     * This field corresponds to the database column user_follow.effective
-     *
-     * @mbg.generated
+     * 生效标示 0-有效 1-失效
      */
     private Integer effective;
 
     /**
-     * Database Column Remarks:
-     *   时间戳
-     *
-     * This field was generated by MyBatis Generator.
-     * This field corresponds to the database column user_follow.time_stamp
-     *
-     * @mbg.generated
+     * 时间戳
      */
     private Date timeStamp;
 
     /**
-     * Database Column Remarks:
-     *   累计拜访次数
-     *
-     * This field was generated by MyBatis Generator.
-     * This field corresponds to the database column user_follow.follow_count
-     *
-     * @mbg.generated
+     * 累计拜访次数
      */
     private Integer followCount;
 
     /**
-     * Database Column Remarks:
-     *   指导意见
-     *
-     * This field was generated by MyBatis Generator.
-     * This field corresponds to the database column user_follow.guidance
-     *
-     * @mbg.generated
+     * 指导意见
      */
     private String guidance;
 
     /**
-     * Database Column Remarks:
-     *   指导时间
-     *
-     * This field was generated by MyBatis Generator.
-     * This field corresponds to the database column user_follow.guidance_time
-     *
-     * @mbg.generated
+     * 指导时间
      */
     private Date guidanceTime;
 
     /**
-     * Database Column Remarks:
-     *   指导人编号
-     *
-     * This field was generated by MyBatis Generator.
-     * This field corresponds to the database column user_follow.guidance_aid
-     *
-     * @mbg.generated
+     * 指导人编号
      */
     private String guidanceAid;
 
     /**
-     * Database Column Remarks:
-     *   指导人名称
-     *
-     * This field was generated by MyBatis Generator.
-     * This field corresponds to the database column user_follow.guidance_name
-     *
-     * @mbg.generated
+     * 指导人名称
      */
     private String guidanceName;
 
-
+    /**
+     * 跟进人名称
+     */
     private String followName;
-    private String followDep;
-
-    public String getFollowName() {
-        return followName;
-    }
-
-    public void setFollowName(String followName) {
-        this.followName = followName;
-    }
-
-    public String getFollowDep() {
-        return followDep;
-    }
 
-    public void setFollowDep(String followDep) {
-        this.followDep = followDep;
-    }
+    /**
+     * 跟进人部门
+     */
+    private String followDep;
 
     /**
-     * This field was generated by MyBatis Generator.
-     * This field corresponds to the database table user_follow
-     *
-     * @mbg.generated
+     * 0 客户跟进 1项目跟进
      */
+    private Integer type;
+
     private static final long serialVersionUID = 1L;
 
     /**
-     * This method was generated by MyBatis Generator.
-     * This method returns the value of the database column user_follow.id
-     *
-     * @return the value of user_follow.id
-     *
-     * @mbg.generated
+     * 
      */
     public String getId() {
         return id;
     }
 
     /**
-     * This method was generated by MyBatis Generator.
-     * This method sets the value of the database column user_follow.id
-     *
-     * @param id the value for user_follow.id
-     *
-     * @mbg.generated
+     * 
      */
     public void setId(String id) {
-        this.id = id == null ? null : id.trim();
+        this.id = id;
     }
 
     /**
-     * This method was generated by MyBatis Generator.
-     * This method returns the value of the database column user_follow.uid
-     *
-     * @return the value of user_follow.uid
-     *
-     * @mbg.generated
+     * 客户ID
      */
     public String getUid() {
         return uid;
     }
 
     /**
-     * This method was generated by MyBatis Generator.
-     * This method sets the value of the database column user_follow.uid
-     *
-     * @param uid the value for user_follow.uid
-     *
-     * @mbg.generated
+     * 客户ID
      */
     public void setUid(String uid) {
-        this.uid = uid == null ? null : uid.trim();
+        this.uid = uid;
     }
 
     /**
-     * This method was generated by MyBatis Generator.
-     * This method returns the value of the database column user_follow.aid
-     *
-     * @return the value of user_follow.aid
-     *
-     * @mbg.generated
+     * 营销员ID
      */
     public String getAid() {
         return aid;
     }
 
     /**
-     * This method was generated by MyBatis Generator.
-     * This method sets the value of the database column user_follow.aid
-     *
-     * @param aid the value for user_follow.aid
-     *
-     * @mbg.generated
+     * 营销员ID
      */
     public void setAid(String aid) {
-        this.aid = aid == null ? null : aid.trim();
+        this.aid = aid;
     }
 
     /**
-     * This method was generated by MyBatis Generator.
-     * This method returns the value of the database column user_follow.paid
-     *
-     * @return the value of user_follow.paid
-     *
-     * @mbg.generated
+     * 营销员上级集合
      */
     public String getPaid() {
         return paid;
     }
 
     /**
-     * This method was generated by MyBatis Generator.
-     * This method sets the value of the database column user_follow.paid
-     *
-     * @param paid the value for user_follow.paid
-     *
-     * @mbg.generated
+     * 营销员上级集合
      */
     public void setPaid(String paid) {
-        this.paid = paid == null ? null : paid.trim();
+        this.paid = paid;
     }
 
     /**
-     * This method was generated by MyBatis Generator.
-     * This method returns the value of the database column user_follow.result
-     *
-     * @return the value of user_follow.result
-     *
-     * @mbg.generated
+     * 跟进结果
      */
     public String getResult() {
         return result;
     }
 
     /**
-     * This method was generated by MyBatis Generator.
-     * This method sets the value of the database column user_follow.result
-     *
-     * @param result the value for user_follow.result
-     *
-     * @mbg.generated
+     * 跟进结果
      */
     public void setResult(String result) {
-        this.result = result == null ? null : result.trim();
+        this.result = result;
     }
 
     /**
-     * This method was generated by MyBatis Generator.
-     * This method returns the value of the database column user_follow.attachment_url
-     *
-     * @return the value of user_follow.attachment_url
-     *
-     * @mbg.generated
+     * 附件地址
      */
     public String getAttachmentUrl() {
         return attachmentUrl;
     }
 
     /**
-     * This method was generated by MyBatis Generator.
-     * This method sets the value of the database column user_follow.attachment_url
-     *
-     * @param attachmentUrl the value for user_follow.attachment_url
-     *
-     * @mbg.generated
+     * 附件地址
      */
     public void setAttachmentUrl(String attachmentUrl) {
-        this.attachmentUrl = attachmentUrl == null ? null : attachmentUrl.trim();
+        this.attachmentUrl = attachmentUrl;
     }
 
     /**
-     * This method was generated by MyBatis Generator.
-     * This method returns the value of the database column user_follow.create_time
-     *
-     * @return the value of user_follow.create_time
-     *
-     * @mbg.generated
+     * 跟进时间
      */
     public Date getCreateTime() {
         return createTime;
     }
 
     /**
-     * This method was generated by MyBatis Generator.
-     * This method sets the value of the database column user_follow.create_time
-     *
-     * @param createTime the value for user_follow.create_time
-     *
-     * @mbg.generated
+     * 跟进时间
      */
     public void setCreateTime(Date createTime) {
         this.createTime = createTime;
     }
 
     /**
-     * This method was generated by MyBatis Generator.
-     * This method returns the value of the database column user_follow.ocb_id
-     *
-     * @return the value of user_follow.ocb_id
-     *
-     * @mbg.generated
+     * 企业联系人ID
      */
     public String getOcbId() {
         return ocbId;
     }
 
     /**
-     * This method was generated by MyBatis Generator.
-     * This method sets the value of the database column user_follow.ocb_id
-     *
-     * @param ocbId the value for user_follow.ocb_id
-     *
-     * @mbg.generated
+     * 企业联系人ID
      */
     public void setOcbId(String ocbId) {
-        this.ocbId = ocbId == null ? null : ocbId.trim();
+        this.ocbId = ocbId;
     }
 
     /**
-     * This method was generated by MyBatis Generator.
-     * This method returns the value of the database column user_follow.contact_type
-     *
-     * @return the value of user_follow.contact_type
-     *
-     * @mbg.generated
+     * 联系方式 0外出 1.电话 2.QQ 3.微信  4邮件 5公出打卡
      */
     public Integer getContactType() {
         return contactType;
     }
 
     /**
-     * This method was generated by MyBatis Generator.
-     * This method sets the value of the database column user_follow.contact_type
-     *
-     * @param contactType the value for user_follow.contact_type
-     *
-     * @mbg.generated
+     * 联系方式 0外出 1.电话 2.QQ 3.微信  4邮件 5公出打卡
      */
     public void setContactType(Integer contactType) {
         this.contactType = contactType;
     }
 
     /**
-     * This method was generated by MyBatis Generator.
-     * This method returns the value of the database column user_follow.effective
-     *
-     * @return the value of user_follow.effective
-     *
-     * @mbg.generated
+     * 生效标示 0-有效 1-失效
      */
     public Integer getEffective() {
         return effective;
     }
 
     /**
-     * This method was generated by MyBatis Generator.
-     * This method sets the value of the database column user_follow.effective
-     *
-     * @param effective the value for user_follow.effective
-     *
-     * @mbg.generated
+     * 生效标示 0-有效 1-失效
      */
     public void setEffective(Integer effective) {
         this.effective = effective;
     }
 
     /**
-     * This method was generated by MyBatis Generator.
-     * This method returns the value of the database column user_follow.time_stamp
-     *
-     * @return the value of user_follow.time_stamp
-     *
-     * @mbg.generated
+     * 时间戳
      */
     public Date getTimeStamp() {
         return timeStamp;
     }
 
     /**
-     * This method was generated by MyBatis Generator.
-     * This method sets the value of the database column user_follow.time_stamp
-     *
-     * @param timeStamp the value for user_follow.time_stamp
-     *
-     * @mbg.generated
+     * 时间戳
      */
     public void setTimeStamp(Date timeStamp) {
         this.timeStamp = timeStamp;
     }
 
     /**
-     * This method was generated by MyBatis Generator.
-     * This method returns the value of the database column user_follow.follow_count
-     *
-     * @return the value of user_follow.follow_count
-     *
-     * @mbg.generated
+     * 累计拜访次数
      */
     public Integer getFollowCount() {
         return followCount;
     }
 
     /**
-     * This method was generated by MyBatis Generator.
-     * This method sets the value of the database column user_follow.follow_count
-     *
-     * @param followCount the value for user_follow.follow_count
-     *
-     * @mbg.generated
+     * 累计拜访次数
      */
     public void setFollowCount(Integer followCount) {
         this.followCount = followCount;
     }
 
     /**
-     * This method was generated by MyBatis Generator.
-     * This method returns the value of the database column user_follow.guidance
-     *
-     * @return the value of user_follow.guidance
-     *
-     * @mbg.generated
+     * 指导意见
      */
     public String getGuidance() {
         return guidance;
     }
 
     /**
-     * This method was generated by MyBatis Generator.
-     * This method sets the value of the database column user_follow.guidance
-     *
-     * @param guidance the value for user_follow.guidance
-     *
-     * @mbg.generated
+     * 指导意见
      */
     public void setGuidance(String guidance) {
-        this.guidance = guidance == null ? null : guidance.trim();
+        this.guidance = guidance;
     }
 
     /**
-     * This method was generated by MyBatis Generator.
-     * This method returns the value of the database column user_follow.guidance_time
-     *
-     * @return the value of user_follow.guidance_time
-     *
-     * @mbg.generated
+     * 指导时间
      */
     public Date getGuidanceTime() {
         return guidanceTime;
     }
 
     /**
-     * This method was generated by MyBatis Generator.
-     * This method sets the value of the database column user_follow.guidance_time
-     *
-     * @param guidanceTime the value for user_follow.guidance_time
-     *
-     * @mbg.generated
+     * 指导时间
      */
     public void setGuidanceTime(Date guidanceTime) {
         this.guidanceTime = guidanceTime;
     }
 
     /**
-     * This method was generated by MyBatis Generator.
-     * This method returns the value of the database column user_follow.guidance_aid
-     *
-     * @return the value of user_follow.guidance_aid
-     *
-     * @mbg.generated
+     * 指导人编号
      */
     public String getGuidanceAid() {
         return guidanceAid;
     }
 
     /**
-     * This method was generated by MyBatis Generator.
-     * This method sets the value of the database column user_follow.guidance_aid
-     *
-     * @param guidanceAid the value for user_follow.guidance_aid
-     *
-     * @mbg.generated
+     * 指导人编号
      */
     public void setGuidanceAid(String guidanceAid) {
-        this.guidanceAid = guidanceAid == null ? null : guidanceAid.trim();
+        this.guidanceAid = guidanceAid;
     }
 
     /**
-     * This method was generated by MyBatis Generator.
-     * This method returns the value of the database column user_follow.guidance_name
-     *
-     * @return the value of user_follow.guidance_name
-     *
-     * @mbg.generated
+     * 指导人名称
      */
     public String getGuidanceName() {
         return guidanceName;
     }
 
     /**
-     * This method was generated by MyBatis Generator.
-     * This method sets the value of the database column user_follow.guidance_name
-     *
-     * @param guidanceName the value for user_follow.guidance_name
-     *
-     * @mbg.generated
+     * 指导人名称
      */
     public void setGuidanceName(String guidanceName) {
-        this.guidanceName = guidanceName == null ? null : guidanceName.trim();
-    }
-
-    /**
-     * This method was generated by MyBatis Generator.
-     * This method corresponds to the database table user_follow
-     *
-     * @mbg.generated
-     */
-    @Override
-    public String toString() {
-        StringBuilder sb = new StringBuilder();
-        sb.append(getClass().getSimpleName());
-        sb.append(" [");
-        sb.append("Hash = ").append(hashCode());
-        sb.append(", id=").append(id);
-        sb.append(", uid=").append(uid);
-        sb.append(", aid=").append(aid);
-        sb.append(", paid=").append(paid);
-        sb.append(", result=").append(result);
-        sb.append(", attachmentUrl=").append(attachmentUrl);
-        sb.append(", createTime=").append(createTime);
-        sb.append(", ocbId=").append(ocbId);
-        sb.append(", contactType=").append(contactType);
-        sb.append(", effective=").append(effective);
-        sb.append(", timeStamp=").append(timeStamp);
-        sb.append(", followCount=").append(followCount);
-        sb.append(", guidance=").append(guidance);
-        sb.append(", guidanceTime=").append(guidanceTime);
-        sb.append(", guidanceAid=").append(guidanceAid);
-        sb.append(", guidanceName=").append(guidanceName);
-        sb.append(", serialVersionUID=").append(serialVersionUID);
-        sb.append("]");
-        return sb.toString();
+        this.guidanceName = guidanceName;
+    }
+
+    /**
+     * 跟进人名称
+     */
+    public String getFollowName() {
+        return followName;
+    }
+
+    /**
+     * 跟进人名称
+     */
+    public void setFollowName(String followName) {
+        this.followName = followName;
+    }
+
+    /**
+     * 跟进人部门
+     */
+    public String getFollowDep() {
+        return followDep;
+    }
+
+    /**
+     * 跟进人部门
+     */
+    public void setFollowDep(String followDep) {
+        this.followDep = followDep;
+    }
+
+    /**
+     * 0 客户跟进 1项目跟进
+     */
+    public Integer getType() {
+        return type;
+    }
+
+    /**
+     * 0 客户跟进 1项目跟进
+     */
+    public void setType(Integer type) {
+        this.type = type;
     }
 }