ソースを参照

公客显示推广人员字段

魏熙美 5 年 前
コミット
5d6dcfbc23

+ 1
- 1
src/main/java/com/huiju/estateagents/mapper/TaRecommendCustomerMapper.java ファイルの表示

@@ -44,7 +44,7 @@ public interface TaRecommendCustomerMapper extends BaseMapper<TaRecommendCustome
44 44
      * @param sex
45 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
- 1
src/main/java/com/huiju/estateagents/service/impl/TaRecommendCustomerServiceImpl.java ファイルの表示

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

+ 3
- 2
src/main/resources/mapper/TaRecommendCustomerMapper.xml ファイルの表示

@@ -154,7 +154,7 @@ FROM
154 154
         b.tel as consultTel,
155 155
         c.nickname as recommendName,
156 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 158
         FROM
159 159
         ta_recommend_customer a
160 160
         LEFT JOIN ta_person b ON a.realty_consultant = b.person_id
@@ -207,7 +207,8 @@ FROM
207 207
 
208 208
     <select id="getPublicCustomerList" resultType="com.huiju.estateagents.entity.TaPerson">
209 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 212
                 FROM
212 213
                 ta_person b
213 214
                <where>