Ver código fonte

Merge branch 'v3.5' of http://git.ycjcjy.com/zhiyuxing/estateagents into v3.5

胡轶钦 5 anos atrás
pai
commit
2315ed3c9b

+ 1
- 1
src/main/java/com/huiju/estateagents/mapper/TaRecommendCustomerMapper.java Ver arquivo

44
      * @param sex
44
      * @param sex
45
      * @return
45
      * @return
46
      */
46
      */
47
-    IPage<TaPerson> getPublicCustomerList(IPage<TaPerson> page, @Param("buildingId") String buildingId, @Param("name") String name, @Param("tel") String tel,@Param("entryType") String entryType,@Param("verifyStatus") String verifyStatus,@Param("sex") Integer sex, @Param("orgId") Integer orgId,@Param("consultTel")String consultTel);
47
+    IPage<TaPerson> getPublicCustomerList(IPage<TaPerson> page, @Param("name") String name, @Param("tel") String tel,@Param("entryType") String entryType,@Param("verifyStatus") String verifyStatus,@Param("sex") Integer sex, @Param("orgId") Integer orgId,@Param("consultTel")String consultTel);
48
 
48
 
49
     /**
49
     /**
50
      * 导出数据 获取推荐用户数据
50
      * 导出数据 获取推荐用户数据

+ 2
- 0
src/main/java/com/huiju/estateagents/service/impl/TaBuildingDynamicServiceImpl.java Ver arquivo

398
                 taBuildingDynamic.setPosters(taPosterService.getPostersForTarget(taBuildingDynamic.getDynamicId(), CommConstant.POSTER_CONTENT_TYPE_ACTIVITY));
398
                 taBuildingDynamic.setPosters(taPosterService.getPostersForTarget(taBuildingDynamic.getDynamicId(), CommConstant.POSTER_CONTENT_TYPE_ACTIVITY));
399
                 taBuildingDynamic.setShareContents(taShareContentService.getPostersForTarget(taBuildingDynamic.getDynamicId(), CommConstant.POSTER_CONTENT_TYPE_ACTIVITY));
399
                 taBuildingDynamic.setShareContents(taShareContentService.getPostersForTarget(taBuildingDynamic.getDynamicId(), CommConstant.POSTER_CONTENT_TYPE_ACTIVITY));
400
 
400
 
401
+                //更改状态为已参与
402
+                taBuildingDynamic.setActivityStatus(CommConstant.ACTIVITY_STATUS_PARTNER);
401
 
403
 
402
             }
404
             }
403
             return result;
405
             return result;

+ 2
- 1
src/main/java/com/huiju/estateagents/service/impl/TaRecommendCustomerServiceImpl.java Ver arquivo

399
 
399
 
400
             // 公客
400
             // 公客
401
             IPage<TaPerson>page = new Page<>(pageNumber,pageSize);
401
             IPage<TaPerson>page = new Page<>(pageNumber,pageSize);
402
-            return taRecommendCustomerMapper.getPublicCustomerList(page, building,name, tel,  entryType, verifyStatus, sex, orgId,consultTel);
402
+            // 公客就不用 buildingId 进行查询
403
+            return taRecommendCustomerMapper.getPublicCustomerList(page,name, tel,  entryType, verifyStatus, sex, orgId,consultTel);
403
         } else {
404
         } else {
404
             // 私客
405
             // 私客
405
             IPage<TaRecommendCustomer>page = new Page<>(pageNumber,pageSize);
406
             IPage<TaRecommendCustomer>page = new Page<>(pageNumber,pageSize);

+ 11
- 3
src/main/resources/mapper/HelpActivityMapper.xml Ver arquivo

62
 			FROM
62
 			FROM
63
 				ta_help_activity a
63
 				ta_help_activity a
64
 				WHERE
64
 				WHERE
65
-                  a.org_id =#{orgId}
65
+                    a.org_id =#{orgId}
66
+                <if test="buildingId  == null ">
66
                   and  a.is_main = 1
67
                   and  a.is_main = 1
67
-                  and  a.city_id = #{cityID}
68
+                </if>
69
+                <if test="cityID != null and cityID != ''">
70
+                      and  a.city_id = #{cityID}
71
+                </if>
68
                 <if test="buildingId != null and buildingId != ''">
72
                 <if test="buildingId != null and buildingId != ''">
69
                   and a.building_id = #{buildingId}
73
                   and a.building_id = #{buildingId}
70
                 </if>
74
                 </if>
79
 				FROM
83
 				FROM
80
 					ta_share_activity s
84
 					ta_share_activity s
81
 					WHERE
85
 					WHERE
82
-                        s.org_id =#{orgId}
86
+                    s.org_id =#{orgId}
87
+                <if test="buildingId  == null ">
83
                     and  s.sort = 1
88
                     and  s.sort = 1
89
+                </if>
90
+                <if test="cityID != null and cityID != ''">
84
                     and  s.city_id = #{cityID}
91
                     and  s.city_id = #{cityID}
92
+                </if>
85
                 <if test="buildingId != null and buildingId != ''">
93
                 <if test="buildingId != null and buildingId != ''">
86
                     and s.building_id = #{buildingId}
94
                     and s.building_id = #{buildingId}
87
                 </if>
95
                 </if>

+ 3
- 2
src/main/resources/mapper/TaRecommendCustomerMapper.xml Ver arquivo

154
         b.tel as consultTel,
154
         b.tel as consultTel,
155
         c.nickname as recommendName,
155
         c.nickname as recommendName,
156
         c.tel as recommendTel,
156
         c.tel as recommendTel,
157
-        (select tpp.name from ta_share_person_from tspf left join ta_person tpp on  tspf.share_person = tpp.person_id where tspf.building_id = #{building} and tspf.is_first_time = 1 and a.person_id = tspf.person_id) as sharePersonName
157
+        (select if(ifnull(tpp.name, '') != '',tpp.name, tpp.nickname) from ta_share_person_from tspf left join ta_person tpp on  tspf.share_person = tpp.person_id where tspf.is_first_time = 1 and a.person_id = tspf.person_id) as sharePersonName
158
         FROM
158
         FROM
159
         ta_recommend_customer a
159
         ta_recommend_customer a
160
         LEFT JOIN ta_person b ON a.realty_consultant = b.person_id
160
         LEFT JOIN ta_person b ON a.realty_consultant = b.person_id
207
 
207
 
208
     <select id="getPublicCustomerList" resultType="com.huiju.estateagents.entity.TaPerson">
208
     <select id="getPublicCustomerList" resultType="com.huiju.estateagents.entity.TaPerson">
209
         SELECT
209
         SELECT
210
-                b.*
210
+                b.*,
211
+                (select if(ifnull(tpp.name, '') != '',tpp.name, tpp.nickname) from ta_share_person_from tspf left join ta_person tpp on  tspf.share_person = tpp.person_id where tspf.is_first_time = 1 and b.person_id = tspf.person_id) as sharePersonName
211
                 FROM
212
                 FROM
212
                 ta_person b
213
                 ta_person b
213
                <where>
214
                <where>