Ver código fonte

公出新增省市区地址

anderx 1 ano atrás
pai
commit
3753c489c5

+ 219 - 255
src/main/java/com/goafanti/common/mapper/PublicReleaseDetailsMapper.xml

@@ -1,263 +1,227 @@
 <?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.PublicReleaseDetailsMapper">
-  <resultMap id="BaseResultMap" type="com.goafanti.common.model.PublicReleaseDetails">
-    <id column="id" jdbcType="INTEGER" property="id" />
-    <result column="prid" jdbcType="INTEGER" property="prid" />
-    <result column="uid" jdbcType="VARCHAR" property="uid" />
-    <result column="ufid" jdbcType="VARCHAR" property="ufid" />
-    <result column="new_user" jdbcType="INTEGER" property="newUser" />
-    <result column="sign_sum" jdbcType="INTEGER" property="signSum" />
-    <result column="longitude" jdbcType="VARCHAR" property="longitude" />
-    <result column="latitude" jdbcType="VARCHAR" property="latitude" />
-    <result column="clock_in" jdbcType="INTEGER" property="clockIn" />
-    <result column="clock_in_time" jdbcType="TIMESTAMP" property="clockInTime" />
-    <result column="photo_url" jdbcType="VARCHAR" property="photoUrl" />
-    <result column="district_name" jdbcType="VARCHAR" property="districtName" />
-    <result column="clock_in_remarks" jdbcType="VARCHAR" property="clockInRemarks" />
-    <result column="duration" jdbcType="DOUBLE" property="duration" />
-    <result column="main_status" jdbcType="INTEGER" property="mainStatus" />
-    <result column="update_time" jdbcType="TIMESTAMP" property="updateTime" />
-  </resultMap>
-  <sql id="Base_Column_List">
-    id, prid, `uid`, ufid, new_user, sign_sum, longitude, latitude, clock_in, clock_in_time,
-    photo_url, district_name, clock_in_remarks, duration, main_status, update_time
-  </sql>
-  <select id="selectByPrimaryKey" parameterType="java.lang.Integer" resultMap="BaseResultMap">
-    select
-    <include refid="Base_Column_List" />
-    from public_release_details
-    where id = #{id,jdbcType=INTEGER}
-  </select>
-  <delete id="deleteByPrimaryKey" parameterType="java.lang.Integer">
-    delete from public_release_details
-    where id = #{id,jdbcType=INTEGER}
-  </delete>
-  <insert id="insert" keyColumn="id" keyProperty="id" parameterType="com.goafanti.common.model.PublicReleaseDetails" useGeneratedKeys="true">
-    insert into public_release_details (prid, `uid`, ufid,
-      new_user, sign_sum, longitude,
-      latitude, clock_in, clock_in_time,
-      photo_url, district_name, clock_in_remarks,
-      duration, main_status, update_time
-      )
-    values (#{prid,jdbcType=INTEGER}, #{uid,jdbcType=VARCHAR}, #{ufid,jdbcType=VARCHAR},
-      #{newUser,jdbcType=INTEGER}, #{signSum,jdbcType=INTEGER}, #{longitude,jdbcType=VARCHAR},
-      #{latitude,jdbcType=VARCHAR}, #{clockIn,jdbcType=INTEGER}, #{clockInTime,jdbcType=TIMESTAMP},
-      #{photoUrl,jdbcType=VARCHAR}, #{districtName,jdbcType=VARCHAR}, #{clockInRemarks,jdbcType=VARCHAR},
-      #{duration,jdbcType=DOUBLE}, #{mainStatus,jdbcType=INTEGER}, #{updateTime,jdbcType=TIMESTAMP}
-      )
-  </insert>
-  <insert id="insertSelective" keyColumn="id" keyProperty="id" parameterType="com.goafanti.common.model.PublicReleaseDetails" useGeneratedKeys="true">
-    insert into public_release_details
-    <trim prefix="(" suffix=")" suffixOverrides=",">
-      <if test="prid != null">
-        prid,
-      </if>
-      <if test="uid != null">
-        `uid`,
-      </if>
-      <if test="ufid != null">
-        ufid,
-      </if>
-      <if test="newUser != null">
-        new_user,
-      </if>
-      <if test="signSum != null">
-        sign_sum,
-      </if>
-      <if test="longitude != null">
-        longitude,
-      </if>
-      <if test="latitude != null">
-        latitude,
-      </if>
-      <if test="clockIn != null">
-        clock_in,
-      </if>
-      <if test="clockInTime != null">
-        clock_in_time,
-      </if>
-      <if test="photoUrl != null">
-        photo_url,
-      </if>
-      <if test="districtName != null">
-        district_name,
-      </if>
-      <if test="clockInRemarks != null">
-        clock_in_remarks,
-      </if>
-      <if test="duration != null">
-        duration,
-      </if>
-      <if test="mainStatus != null">
-        main_status,
-      </if>
-      <if test="updateTime != null">
-        update_time,
-      </if>
-    </trim>
-    <trim prefix="values (" suffix=")" suffixOverrides=",">
-      <if test="prid != null">
-        #{prid,jdbcType=INTEGER},
-      </if>
-      <if test="uid != null">
-        #{uid,jdbcType=VARCHAR},
-      </if>
-      <if test="ufid != null">
-        #{ufid,jdbcType=VARCHAR},
-      </if>
-      <if test="newUser != null">
-        #{newUser,jdbcType=INTEGER},
-      </if>
-      <if test="signSum != null">
-        #{signSum,jdbcType=INTEGER},
-      </if>
-      <if test="longitude != null">
-        #{longitude,jdbcType=VARCHAR},
-      </if>
-      <if test="latitude != null">
-        #{latitude,jdbcType=VARCHAR},
-      </if>
-      <if test="clockIn != null">
-        #{clockIn,jdbcType=INTEGER},
-      </if>
-      <if test="clockInTime != null">
-        #{clockInTime,jdbcType=TIMESTAMP},
-      </if>
-      <if test="photoUrl != null">
-        #{photoUrl,jdbcType=VARCHAR},
-      </if>
-      <if test="districtName != null">
-        #{districtName,jdbcType=VARCHAR},
-      </if>
-      <if test="clockInRemarks != null">
-        #{clockInRemarks,jdbcType=VARCHAR},
-      </if>
-      <if test="duration != null">
-        #{duration,jdbcType=DOUBLE},
-      </if>
-      <if test="mainStatus != null">
-        #{mainStatus,jdbcType=INTEGER},
-      </if>
-      <if test="updateTime != null">
-        #{updateTime,jdbcType=TIMESTAMP},
-      </if>
-    </trim>
-  </insert>
-  <update id="updateByPrimaryKeySelective" parameterType="com.goafanti.common.model.PublicReleaseDetails">
-    update public_release_details
-    <set>
-      <if test="prid != null">
-        prid = #{prid,jdbcType=INTEGER},
-      </if>
-      <if test="uid != null">
-        `uid` = #{uid,jdbcType=VARCHAR},
-      </if>
-      <if test="ufid != null">
-        ufid = #{ufid,jdbcType=VARCHAR},
-      </if>
-      <if test="newUser != null">
-        new_user = #{newUser,jdbcType=INTEGER},
-      </if>
-      <if test="signSum != null">
-        sign_sum = #{signSum,jdbcType=INTEGER},
-      </if>
-      <if test="longitude != null">
-        longitude = #{longitude,jdbcType=VARCHAR},
-      </if>
-      <if test="latitude != null">
-        latitude = #{latitude,jdbcType=VARCHAR},
-      </if>
-      <if test="clockIn != null">
-        clock_in = #{clockIn,jdbcType=INTEGER},
-      </if>
-      <if test="clockInTime != null">
-        clock_in_time = #{clockInTime,jdbcType=TIMESTAMP},
-      </if>
-      <if test="photoUrl != null">
-        photo_url = #{photoUrl,jdbcType=VARCHAR},
-      </if>
-      <if test="districtName != null">
-        district_name = #{districtName,jdbcType=VARCHAR},
-      </if>
-      <if test="clockInRemarks != null">
-        clock_in_remarks = #{clockInRemarks,jdbcType=VARCHAR},
-      </if>
-      <if test="duration != null">
-        duration = #{duration,jdbcType=DOUBLE},
-      </if>
-      <if test="mainStatus != null">
-        main_status = #{mainStatus,jdbcType=INTEGER},
-      </if>
-      <if test="updateTime != null">
-        update_time = #{updateTime,jdbcType=TIMESTAMP},
-      </if>
-    </set>
-    where id = #{id,jdbcType=INTEGER}
-  </update>
-  <update id="updateByPrimaryKey" parameterType="com.goafanti.common.model.PublicReleaseDetails">
-    update public_release_details
-    set prid = #{prid,jdbcType=INTEGER},
-      `uid` = #{uid,jdbcType=VARCHAR},
-      ufid = #{ufid,jdbcType=VARCHAR},
-      new_user = #{newUser,jdbcType=INTEGER},
-      sign_sum = #{signSum,jdbcType=INTEGER},
-      longitude = #{longitude,jdbcType=VARCHAR},
-      latitude = #{latitude,jdbcType=VARCHAR},
-      clock_in = #{clockIn,jdbcType=INTEGER},
-      clock_in_time = #{clockInTime,jdbcType=TIMESTAMP},
-      photo_url = #{photoUrl,jdbcType=VARCHAR},
-      district_name = #{districtName,jdbcType=VARCHAR},
-      clock_in_remarks = #{clockInRemarks,jdbcType=VARCHAR},
-      duration = #{duration,jdbcType=DOUBLE},
-      main_status = #{mainStatus,jdbcType=INTEGER},
-      update_time = #{updateTime,jdbcType=TIMESTAMP}
-    where id = #{id,jdbcType=INTEGER}
-  </update>
 
+    <resultMap id="BaseResultMap" type="com.goafanti.common.model.PublicReleaseDetails">
+            <id property="id" column="id" jdbcType="INTEGER"/>
+            <result property="prid" column="prid" jdbcType="INTEGER"/>
+            <result property="uid" column="uid" jdbcType="VARCHAR"/>
+            <result property="ufid" column="ufid" jdbcType="VARCHAR"/>
+            <result property="newUser" column="new_user" jdbcType="INTEGER"/>
+            <result property="signSum" column="sign_sum" jdbcType="INTEGER"/>
+            <result property="longitude" column="longitude" jdbcType="VARCHAR"/>
+            <result property="latitude" column="latitude" jdbcType="VARCHAR"/>
+            <result property="clockIn" column="clock_in" jdbcType="INTEGER"/>
+            <result property="clockInTime" column="clock_in_time" jdbcType="TIMESTAMP"/>
+            <result property="photoUrl" column="photo_url" jdbcType="VARCHAR"/>
+            <result property="districtName" column="district_name" jdbcType="VARCHAR"/>
+            <result property="clockInRemarks" column="clock_in_remarks" jdbcType="VARCHAR"/>
+            <result property="duration" column="duration" jdbcType="DOUBLE"/>
+            <result property="mainStatus" column="main_status" jdbcType="INTEGER"/>
+            <result property="updateTime" column="update_time" jdbcType="TIMESTAMP"/>
+            <result property="addressName" column="address_name" jdbcType="VARCHAR"/>
+    </resultMap>
 
-  <select id="selectByPrid" resultType="com.goafanti.weChat.bo.OutPublicReleaseDetails">
-    select
-      a.id,a.prid, a.`uid`, a.ufid, a.new_user newUser,a.longitude,a.latitude,b.nickname userName,a.main_status mainStatus,a.duration,
-      a.district_name districtName ,a.clock_in clockIn,date_format(a.clock_in_time, '%Y-%m-%d %H:%i:%S')  clockInTimes,a.photo_url photoUrl
-    from public_release_details a left join user b on a.uid=b.id
-    where prid = #{id,jdbcType=INTEGER} order by a.update_time desc
-  </select>
+    <sql id="Base_Column_List">
+        id,prid,uid,
+        ufid,new_user,sign_sum,
+        longitude,latitude,clock_in,
+        clock_in_time,photo_url,district_name,
+        clock_in_remarks,duration,main_status,
+        update_time,address_name
+    </sql>
 
-  <insert id="insertBatch">
-    insert into public_release_details (prid, `uid`, ufid,
-    new_user, sign_sum, longitude,
-    latitude, clock_in, clock_in_time,
-    photo_url, district_name,duration,main_status)
-    values
-    <foreach  collection="list" item="prd"  separator=",">
-      (#{prd.prid,jdbcType=INTEGER}, #{prd.uid,jdbcType=VARCHAR}, #{prd.ufid,jdbcType=VARCHAR},
-      #{prd.newUser,jdbcType=INTEGER}, #{prd.signSum,jdbcType=INTEGER}, #{prd.longitude,jdbcType=VARCHAR},
-      #{prd.latitude,jdbcType=VARCHAR}, #{prd.clockIn,jdbcType=INTEGER}, #{prd.clockInTime,jdbcType=TIMESTAMP},
-      #{prd.photoUrl,jdbcType=VARCHAR}, #{prd.districtName,jdbcType=VARCHAR},#{prd.duration,jdbcType=DOUBLE},
-      #{prd.mainStatus,jdbcType=INTEGER})
-    </foreach>
-  </insert>
+    <select id="selectByPrimaryKey" parameterType="java.lang.Integer" resultMap="BaseResultMap">
+        select
+        <include refid="Base_Column_List" />
+        from public_release_details
+        where  id = #{id,jdbcType=INTEGER} 
+    </select>
 
-  <select id="getNamesByPrid" resultType="java.lang.String">
-    select  GROUP_CONCAT(b.nickname)userNames
-    from public_release_details a left join user b on a.uid =b.id
-    where prid = #{id}
-    group by prid
-  </select>
-  <select id="selectBypridAndUid" resultType="com.goafanti.weChat.bo.OutPublicReleaseDetails">
-    select
-      a.id,a.prid, a.`uid`, a.ufid, a.new_user newUser,a.longitude,a.latitude,b.nickname userName,
-      a.district_name districtName ,a.clock_in clockIn,date_format(a.clock_in_time, '%Y-%m-%d %H:%i:%S')  clockInTimes,a.photo_url photoUrl
-    from public_release_details a left join user b on a.uid=b.id
-    where prid = #{id,jdbcType=INTEGER} and uid =#{uid}
-  </select>
+    <delete id="deleteByPrimaryKey" parameterType="java.lang.Integer">
+        delete from public_release_details
+        where  id = #{id,jdbcType=INTEGER} 
+    </delete>
+    <insert id="insert" keyColumn="id" keyProperty="id" parameterType="com.goafanti.common.model.PublicReleaseDetails" useGeneratedKeys="true">
+        insert into public_release_details
+        ( id,prid,uid
+        ,ufid,new_user,sign_sum
+        ,longitude,latitude,clock_in
+        ,clock_in_time,photo_url,district_name
+        ,clock_in_remarks,duration,main_status
+        ,update_time,address_name)
+        values (#{id,jdbcType=INTEGER},#{prid,jdbcType=INTEGER},#{uid,jdbcType=VARCHAR}
+        ,#{ufid,jdbcType=VARCHAR},#{newUser,jdbcType=INTEGER},#{signSum,jdbcType=INTEGER}
+        ,#{longitude,jdbcType=VARCHAR},#{latitude,jdbcType=VARCHAR},#{clockIn,jdbcType=INTEGER}
+        ,#{clockInTime,jdbcType=TIMESTAMP},#{photoUrl,jdbcType=VARCHAR},#{districtName,jdbcType=VARCHAR}
+        ,#{clockInRemarks,jdbcType=VARCHAR},#{duration,jdbcType=DOUBLE},#{mainStatus,jdbcType=INTEGER}
+        ,#{updateTime,jdbcType=TIMESTAMP},#{addressName,jdbcType=VARCHAR})
+    </insert>
+    <insert id="insertSelective" keyColumn="id" keyProperty="id" parameterType="com.goafanti.common.model.PublicReleaseDetails" useGeneratedKeys="true">
+        insert into public_release_details
+        <trim prefix="(" suffix=")" suffixOverrides=",">
+                <if test="id != null">id,</if>
+                <if test="prid != null">prid,</if>
+                <if test="uid != null">uid,</if>
+                <if test="ufid != null">ufid,</if>
+                <if test="newUser != null">new_user,</if>
+                <if test="signSum != null">sign_sum,</if>
+                <if test="longitude != null">longitude,</if>
+                <if test="latitude != null">latitude,</if>
+                <if test="clockIn != null">clock_in,</if>
+                <if test="clockInTime != null">clock_in_time,</if>
+                <if test="photoUrl != null">photo_url,</if>
+                <if test="districtName != null">district_name,</if>
+                <if test="clockInRemarks != null">clock_in_remarks,</if>
+                <if test="duration != null">duration,</if>
+                <if test="mainStatus != null">main_status,</if>
+                <if test="updateTime != null">update_time,</if>
+                <if test="addressName != null">address_name,</if>
+        </trim>
+        <trim prefix="values (" suffix=")" suffixOverrides=",">
+                <if test="id != null">#{id,jdbcType=INTEGER},</if>
+                <if test="prid != null">#{prid,jdbcType=INTEGER},</if>
+                <if test="uid != null">#{uid,jdbcType=VARCHAR},</if>
+                <if test="ufid != null">#{ufid,jdbcType=VARCHAR},</if>
+                <if test="newUser != null">#{newUser,jdbcType=INTEGER},</if>
+                <if test="signSum != null">#{signSum,jdbcType=INTEGER},</if>
+                <if test="longitude != null">#{longitude,jdbcType=VARCHAR},</if>
+                <if test="latitude != null">#{latitude,jdbcType=VARCHAR},</if>
+                <if test="clockIn != null">#{clockIn,jdbcType=INTEGER},</if>
+                <if test="clockInTime != null">#{clockInTime,jdbcType=TIMESTAMP},</if>
+                <if test="photoUrl != null">#{photoUrl,jdbcType=VARCHAR},</if>
+                <if test="districtName != null">#{districtName,jdbcType=VARCHAR},</if>
+                <if test="clockInRemarks != null">#{clockInRemarks,jdbcType=VARCHAR},</if>
+                <if test="duration != null">#{duration,jdbcType=DOUBLE},</if>
+                <if test="mainStatus != null">#{mainStatus,jdbcType=INTEGER},</if>
+                <if test="updateTime != null">#{updateTime,jdbcType=TIMESTAMP},</if>
+                <if test="addressName != null">#{addressName,jdbcType=VARCHAR},</if>
+        </trim>
+    </insert>
+    <update id="updateByPrimaryKeySelective" parameterType="com.goafanti.common.model.PublicReleaseDetails">
+        update public_release_details
+        <set>
+                <if test="prid != null">
+                    prid = #{prid,jdbcType=INTEGER},
+                </if>
+                <if test="uid != null">
+                    uid = #{uid,jdbcType=VARCHAR},
+                </if>
+                <if test="ufid != null">
+                    ufid = #{ufid,jdbcType=VARCHAR},
+                </if>
+                <if test="newUser != null">
+                    new_user = #{newUser,jdbcType=INTEGER},
+                </if>
+                <if test="signSum != null">
+                    sign_sum = #{signSum,jdbcType=INTEGER},
+                </if>
+                <if test="longitude != null">
+                    longitude = #{longitude,jdbcType=VARCHAR},
+                </if>
+                <if test="latitude != null">
+                    latitude = #{latitude,jdbcType=VARCHAR},
+                </if>
+                <if test="clockIn != null">
+                    clock_in = #{clockIn,jdbcType=INTEGER},
+                </if>
+                <if test="clockInTime != null">
+                    clock_in_time = #{clockInTime,jdbcType=TIMESTAMP},
+                </if>
+                <if test="photoUrl != null">
+                    photo_url = #{photoUrl,jdbcType=VARCHAR},
+                </if>
+                <if test="districtName != null">
+                    district_name = #{districtName,jdbcType=VARCHAR},
+                </if>
+                <if test="clockInRemarks != null">
+                    clock_in_remarks = #{clockInRemarks,jdbcType=VARCHAR},
+                </if>
+                <if test="duration != null">
+                    duration = #{duration,jdbcType=DOUBLE},
+                </if>
+                <if test="mainStatus != null">
+                    main_status = #{mainStatus,jdbcType=INTEGER},
+                </if>
+                <if test="updateTime != null">
+                    update_time = #{updateTime,jdbcType=TIMESTAMP},
+                </if>
+                <if test="addressName != null">
+                    address_name = #{addressName,jdbcType=VARCHAR},
+                </if>
+        </set>
+        where   id = #{id,jdbcType=INTEGER} 
+    </update>
+    <update id="updateByPrimaryKey" parameterType="com.goafanti.common.model.PublicReleaseDetails">
+        update public_release_details
+        set 
+            prid =  #{prid,jdbcType=INTEGER},
+            uid =  #{uid,jdbcType=VARCHAR},
+            ufid =  #{ufid,jdbcType=VARCHAR},
+            new_user =  #{newUser,jdbcType=INTEGER},
+            sign_sum =  #{signSum,jdbcType=INTEGER},
+            longitude =  #{longitude,jdbcType=VARCHAR},
+            latitude =  #{latitude,jdbcType=VARCHAR},
+            clock_in =  #{clockIn,jdbcType=INTEGER},
+            clock_in_time =  #{clockInTime,jdbcType=TIMESTAMP},
+            photo_url =  #{photoUrl,jdbcType=VARCHAR},
+            district_name =  #{districtName,jdbcType=VARCHAR},
+            clock_in_remarks =  #{clockInRemarks,jdbcType=VARCHAR},
+            duration =  #{duration,jdbcType=DOUBLE},
+            main_status =  #{mainStatus,jdbcType=INTEGER},
+            update_time =  #{updateTime,jdbcType=TIMESTAMP},
+            address_name =  #{addressName,jdbcType=VARCHAR}
+        where   id = #{id,jdbcType=INTEGER} 
+    </update>
 
-  <update id="updateDistrictByPrid">
-    update public_release_details
-    set longitude = #{longitude,jdbcType=VARCHAR},
-        latitude = #{latitude,jdbcType=VARCHAR},
-        district_name = #{districtName,jdbcType=VARCHAR}
-    where prid =#{id}
-  </update>
+
+
+
+    <select id="selectByPrid" resultType="com.goafanti.weChat.bo.OutPublicReleaseDetails">
+        select
+            a.id,a.prid, a.`uid`, a.ufid, a.new_user newUser,a.longitude,a.latitude,b.nickname userName,a.main_status mainStatus,a.duration,
+            a.district_name districtName ,a.clock_in clockIn,date_format(a.clock_in_time, '%Y-%m-%d %H:%i:%S')  clockInTimes,a.photo_url photoUrl
+        from public_release_details a left join user b on a.uid=b.id
+        where prid = #{id,jdbcType=INTEGER} order by a.update_time desc
+    </select>
+
+    <insert id="insertBatch">
+        insert into public_release_details (prid, `uid`, ufid,
+        new_user, sign_sum, longitude,
+        latitude, clock_in, clock_in_time,
+        photo_url, district_name,duration,main_status,address_name)
+        values
+        <foreach  collection="list" item="prd"  separator=",">
+            (#{prd.prid,jdbcType=INTEGER}, #{prd.uid,jdbcType=VARCHAR}, #{prd.ufid,jdbcType=VARCHAR},
+            #{prd.newUser,jdbcType=INTEGER}, #{prd.signSum,jdbcType=INTEGER}, #{prd.longitude,jdbcType=VARCHAR},
+            #{prd.latitude,jdbcType=VARCHAR}, #{prd.clockIn,jdbcType=INTEGER}, #{prd.clockInTime,jdbcType=TIMESTAMP},
+            #{prd.photoUrl,jdbcType=VARCHAR}, #{prd.districtName,jdbcType=VARCHAR},#{prd.duration,jdbcType=DOUBLE},
+            #{prd.mainStatus,jdbcType=INTEGER},#{prd.addressName,jdbcType=VARCHAR})
+        </foreach>
+    </insert>
+
+    <select id="getNamesByPrid" resultType="java.lang.String">
+        select  GROUP_CONCAT(b.nickname)userNames
+        from public_release_details a left join user b on a.uid =b.id
+        where prid = #{id}
+        group by prid
+    </select>
+    <select id="selectBypridAndUid" resultType="com.goafanti.weChat.bo.OutPublicReleaseDetails">
+        select
+            a.id,a.prid, a.`uid`, a.ufid, a.new_user newUser,a.longitude,a.latitude,b.nickname userName,
+            a.district_name districtName ,a.clock_in clockIn,date_format(a.clock_in_time, '%Y-%m-%d %H:%i:%S')  clockInTimes,a.photo_url photoUrl
+        from public_release_details a left join user b on a.uid=b.id
+        where prid = #{id,jdbcType=INTEGER} and uid =#{uid}
+    </select>
+
+    <update id="updateDistrictByPrid">
+        update public_release_details
+        set longitude = #{longitude,jdbcType=VARCHAR},
+            latitude = #{latitude,jdbcType=VARCHAR},
+            district_name = #{districtName,jdbcType=VARCHAR}
+        where prid =#{id}
+    </update>
 </mapper>
+

+ 1 - 1
src/main/java/com/goafanti/common/mapper/PublicReleaseMapper.xml

@@ -573,7 +573,7 @@
         select a.id prdId,b.id,a.district_name districtName ,c.name aname,a.duration ,b.status ,b.annex_url annexUrl,a.photo_url photoUrl,d.nickname userName,
         date_format(a.clock_in_time ,'%Y-%m-%d %H:%i:%S') clockInTimes,a.clock_in clockIn ,b.remarks ,b.supplement ,b.`type` ,b.object_type objectType ,
         date_format(b.create_time ,'%Y-%m-%d %H:%i:%S') createTimes,b.audit_info auditInfo,date_format(b.audit_time ,'%Y-%m-%d %H:%i:%S') auditTimes,
-        date_format(b.release_start,'%Y-%m-%d %H:%i:%S') releaseStarts,date_format(b.release_end ,'%Y-%m-%d %H:%i:%S') releaseEnds,
+        date_format(b.release_start,'%Y-%m-%d %H:%i:%S') releaseStarts,date_format(b.release_end ,'%Y-%m-%d %H:%i:%S') releaseEnds,a.address_name addressName,
         b.plan ,b.next_plan nextPlan ,b.expected_effect expectedEffect,b.update_status updateStatus,b.assist_aid_name assistAidName,
         b.main_name mainName,b.assist,b.assistant_aid assistantAid, b.assistant_name assistantName,f.contract_no contractNo,
         e.name sname,f.total_amount  totalAmout,d.sign_bills signBills,date_format(d.sign_time,'%Y-%m-%d')signTime

+ 120 - 2
src/main/java/com/goafanti/common/model/PublicReleaseDetails.java

@@ -4,10 +4,13 @@ import java.io.Serializable;
 import java.util.Date;
 
 /**
- * public_release_details
- * @author 
+ * 公出详情表
+ * @TableName public_release_details
  */
 public class PublicReleaseDetails implements Serializable {
+    /**
+     * 
+     */
     private Integer id;
 
     /**
@@ -85,133 +88,248 @@ public class PublicReleaseDetails implements Serializable {
      */
     private Date updateTime;
 
+    /**
+     * 公出企业地址
+     */
+    private String addressName;
+
     private static final long serialVersionUID = 1L;
 
+    /**
+     * 
+     */
     public Integer getId() {
         return id;
     }
 
+    /**
+     * 
+     */
     public void setId(Integer id) {
         this.id = id;
     }
 
+    /**
+     * 公出编号
+     */
     public Integer getPrid() {
         return prid;
     }
 
+    /**
+     * 公出编号
+     */
     public void setPrid(Integer prid) {
         this.prid = prid;
     }
 
+    /**
+     * 客户id
+     */
     public String getUid() {
         return uid;
     }
 
+    /**
+     * 客户id
+     */
     public void setUid(String uid) {
         this.uid = uid;
     }
 
+    /**
+     * 跟进id
+     */
     public String getUfid() {
         return ufid;
     }
 
+    /**
+     * 跟进id
+     */
     public void setUfid(String ufid) {
         this.ufid = ufid;
     }
 
+    /**
+     * 客户类型 0新客户 1老客户
+     */
     public Integer getNewUser() {
         return newUser;
     }
 
+    /**
+     * 客户类型 0新客户 1老客户
+     */
     public void setNewUser(Integer newUser) {
         this.newUser = newUser;
     }
 
+    /**
+     * 签单数
+     */
     public Integer getSignSum() {
         return signSum;
     }
 
+    /**
+     * 签单数
+     */
     public void setSignSum(Integer signSum) {
         this.signSum = signSum;
     }
 
+    /**
+     * 经度
+     */
     public String getLongitude() {
         return longitude;
     }
 
+    /**
+     * 经度
+     */
     public void setLongitude(String longitude) {
         this.longitude = longitude;
     }
 
+    /**
+     * 纬度
+     */
     public String getLatitude() {
         return latitude;
     }
 
+    /**
+     * 纬度
+     */
     public void setLatitude(String latitude) {
         this.latitude = latitude;
     }
 
+    /**
+     * 打卡状态 1正常打卡 2异常打卡
+     */
     public Integer getClockIn() {
         return clockIn;
     }
 
+    /**
+     * 打卡状态 1正常打卡 2异常打卡
+     */
     public void setClockIn(Integer clockIn) {
         this.clockIn = clockIn;
     }
 
+    /**
+     * 打卡时间
+     */
     public Date getClockInTime() {
         return clockInTime;
     }
 
+    /**
+     * 打卡时间
+     */
     public void setClockInTime(Date clockInTime) {
         this.clockInTime = clockInTime;
     }
 
+    /**
+     * 照片
+     */
     public String getPhotoUrl() {
         return photoUrl;
     }
 
+    /**
+     * 照片
+     */
     public void setPhotoUrl(String photoUrl) {
         this.photoUrl = photoUrl;
     }
 
+    /**
+     * 公出企业地址
+     */
     public String getDistrictName() {
         return districtName;
     }
 
+    /**
+     * 公出企业地址
+     */
     public void setDistrictName(String districtName) {
         this.districtName = districtName;
     }
 
+    /**
+     * 打卡说明
+     */
     public String getClockInRemarks() {
         return clockInRemarks;
     }
 
+    /**
+     * 打卡说明
+     */
     public void setClockInRemarks(String clockInRemarks) {
         this.clockInRemarks = clockInRemarks;
     }
 
+    /**
+     * 时长
+     */
     public Double getDuration() {
         return duration;
     }
 
+    /**
+     * 时长
+     */
     public void setDuration(Double duration) {
         this.duration = duration;
     }
 
+    /**
+     * 0辅助 1主要(根据客户是否是公出人判断)
+     */
     public Integer getMainStatus() {
         return mainStatus;
     }
 
+    /**
+     * 0辅助 1主要(根据客户是否是公出人判断)
+     */
     public void setMainStatus(Integer mainStatus) {
         this.mainStatus = mainStatus;
     }
 
+    /**
+     * 修改时间
+     */
     public Date getUpdateTime() {
         return updateTime;
     }
 
+    /**
+     * 修改时间
+     */
     public void setUpdateTime(Date updateTime) {
         this.updateTime = updateTime;
     }
+
+    /**
+     * 公出企业地址
+     */
+    public String getAddressName() {
+        return addressName;
+    }
+
+    /**
+     * 公出企业地址
+     */
+    public void setAddressName(String addressName) {
+        this.addressName = addressName;
+    }
 }

+ 10 - 0
src/main/java/com/goafanti/weChat/bo/OutPublicDtails.java

@@ -16,6 +16,8 @@ public class OutPublicDtails  {
 	private Integer signBills;
 	@Excel(name = "签单时间")
 	private String signTime;
+	@Excel(name = "省市区")
+	private String addressName;
 	@Excel(name = "公出地点")
 	private String districtName;
 	@Excel(name = "跟单人")
@@ -71,6 +73,14 @@ public class OutPublicDtails  {
 	@Excel(name = "订单总金额" ,scale = 6)
 	private BigDecimal totalAmout;
 
+	public String getAddressName() {
+		return addressName;
+	}
+
+	public void setAddressName(String addressName) {
+		this.addressName = addressName;
+	}
+
 	private List<PublicReleaseClock> list;
 
 

+ 1 - 0
src/main/java/com/goafanti/weChat/service/impl/PublicReleaseServiceImpl.java

@@ -137,6 +137,7 @@ public class PublicReleaseServiceImpl extends BaseMybatisDao<PublicReleaseMapper
 				prd.setDistrictName(in.getDistrictName());
 				prd.setLatitude(in.getLatitude());
 				prd.setLongitude(in.getLongitude());
+				prd.setAddressName(in.getAddressName());
 				if (index<userCount){
 					if (duration==0){
 						prd.setDuration(duration);