张延森 3 years ago
parent
commit
dd59874d81

+ 1
- 1
pom.xml View File

@@ -10,7 +10,7 @@
10 10
 	</parent>
11 11
 	<groupId>com.yunzhi</groupId>
12 12
 	<artifactId>marketing</artifactId>
13
-	<version>v1.0.32</version>
13
+	<version>v1.0.33</version>
14 14
 	<name>marketing-cloud</name>
15 15
 	<description>新联康营销云</description>
16 16
 

+ 7
- 0
src/main/java/com/yunzhi/marketing/controller/ExtendContentController.java View File

@@ -236,7 +236,14 @@ public class ExtendContentController extends BaseController {
236 236
     @RequestMapping(value="/admin/extendContent/{id}",method= RequestMethod.PUT)
237 237
     public ResponseBean extendContentUpdate(@PathVariable Integer id,
238 238
                                         @RequestBody ExtendContent extendContent,HttpServletRequest request){
239
+
239 240
         ResponseBean responseBean = new ResponseBean();
241
+        ExtendContent origin = iExtendContentService.getById(id);
242
+        if (null == origin) {
243
+            responseBean.addError("未找到更新内容");
244
+            return responseBean;
245
+        }
246
+        extendContent.setStatus(origin.getStatus());
240 247
         extendContent.setContentId(id);
241 248
         try {
242 249
             if (extendContent.getCityId() == null){

+ 6
- 6
src/main/java/com/yunzhi/marketing/controller/TaRecommendCustomerController.java View File

@@ -29,10 +29,7 @@ import com.yunzhi.marketing.service.ITaRecommendCustomerService;
29 29
 import com.yunzhi.marketing.service.TaChannelPersonService;
30 30
 import com.yunzhi.marketing.service.TaChannelService;
31 31
 import com.yunzhi.marketing.excel.*;
32
-import io.swagger.annotations.Api;
33
-import io.swagger.annotations.ApiImplicitParam;
34
-import io.swagger.annotations.ApiImplicitParams;
35
-import io.swagger.annotations.ApiOperation;
32
+import io.swagger.annotations.*;
36 33
 import org.apache.commons.collections.CollectionUtils;
37 34
 import org.apache.ibatis.annotations.Param;
38 35
 import org.springframework.beans.factory.annotation.Autowired;
@@ -525,20 +522,23 @@ public class TaRecommendCustomerController extends BaseController {
525 522
      * 经纪人列表
526 523
      *
527 524
      * @param name
525
+     * @param personId  经纪人ID
528 526
      * @param tel
529 527
      * @param pageNumber
530 528
      * @param pageSize
531 529
      * @return
532 530
      */
533
-    @GetMapping("/admin/customer/agents")
531
+    @GetMapping("/{client}/customer/agents")
534 532
     public ResponseBean getIndependentAgents(HttpServletRequest request,
533
+                                             @PathVariable  String client,
535 534
                                              @RequestParam(value = "name", required = false) String name,
535
+                                             @RequestParam(value = "personId", required = false) String personId,
536 536
                                              @RequestParam(value = "tel", required = false) String tel,
537 537
                                              @RequestParam(value = "channelId", required = false) String channelId,
538 538
                                              @RequestParam(value = "pageNumber", defaultValue = "1") Integer pageNumber,
539 539
                                              @RequestParam(value = "pageSize", defaultValue = "10") Integer pageSize) {
540 540
         try {
541
-            return ResponseBean.success(taRecommendCustomerService.getIndependentAgents(pageNumber, pageSize, name, tel, channelId, getOrgId(request)));
541
+            return ResponseBean.success(taRecommendCustomerService.getIndependentAgents(pageNumber, pageSize, personId, name, tel, channelId, getOrgId(request)));
542 542
         } catch (Exception e) {
543 543
             e.printStackTrace();
544 544
             return ResponseBean.error(e.getMessage(), ResponseBean.ERROR_UNAVAILABLE);

+ 1
- 1
src/main/java/com/yunzhi/marketing/mapper/TaRecommendCustomerMapper.java View File

@@ -40,7 +40,7 @@ public interface TaRecommendCustomerMapper extends BaseMapper<TaRecommendCustome
40 40
 
41 41
     IPage<TaRecommendCustomer> getRepCustomerList(IPage<TaRecommendCustomer> page, @Param("building") String building, @Param("name") String name, @Param("tel") String tel, @Param("consultName") String consultName, @Param("consultTel") String consultTel, @Param("entryType") String entryType, @Param("verifyStatus") String verifyStatus, @Param("sex") Integer sex, @Param("orgId") Integer orgId, @Param("personBuildingList") List<TaPersonBuilding> personBuildingList);
42 42
 
43
-    IPage<TaPerson> getIndependentAgents(IPage<TaPerson> page, @Param("name") String name, @Param("tel") String tel, @Param("channelId") String channelId, @Param("orgId") Integer orgId);
43
+    IPage<TaPerson> getIndependentAgents(IPage<TaPerson> page, @Param("personId") String personId, @Param("name") String name, @Param("tel") String tel, @Param("channelId") String channelId, @Param("orgId") Integer orgId);
44 44
 
45 45
     /**
46 46
      * 公客

+ 1
- 1
src/main/java/com/yunzhi/marketing/service/ITaRecommendCustomerService.java View File

@@ -47,7 +47,7 @@ public interface ITaRecommendCustomerService extends IService<TaRecommendCustome
47 47
 
48 48
     IPage<TaRecommendCustomer> getRepCustomerList(int pageNumber, int pageSize, String building, String name, String tel, String consultName, String consultTel, String entryType, String verifyStatus, Integer sex, Integer orgId, List<TaPersonBuilding> taPersonBuildingList);
49 49
 
50
-    IPage<TaPerson> getIndependentAgents(int pageNumber, int pageSize, String name, String tel, String channelId, Integer orgId);
50
+    IPage<TaPerson> getIndependentAgents(int pageNumber, int pageSize, String personId, String name, String tel, String channelId, Integer orgId);
51 51
 
52 52
 
53 53
     TaRecommendCustomer getCustomerDetail(String customerId, int pageNumber, int pageSize, List<TaPersonBuilding> taPersonBuildingList, String buildingId);

+ 2
- 2
src/main/java/com/yunzhi/marketing/service/impl/TaRecommendCustomerServiceImpl.java View File

@@ -1244,9 +1244,9 @@ public class TaRecommendCustomerServiceImpl extends ServiceImpl<TaRecommendCusto
1244 1244
     }
1245 1245
 
1246 1246
     @Override
1247
-    public IPage<TaPerson> getIndependentAgents(int pageNumber, int pageSize, String name, String tel, String channelId, Integer orgId) {
1247
+    public IPage<TaPerson> getIndependentAgents(int pageNumber, int pageSize, String personId, String name, String tel, String channelId, Integer orgId) {
1248 1248
         IPage<TaPerson> page = new Page<>(pageNumber, pageSize);
1249
-        return taRecommendCustomerMapper.getIndependentAgents(page, name, tel, channelId, orgId);
1249
+        return taRecommendCustomerMapper.getIndependentAgents(page, personId, name, tel, channelId, orgId);
1250 1250
     }
1251 1251
 
1252 1252
     @Override

+ 4
- 0
src/main/java/com/yunzhi/marketing/xlk/vo/CustomerSignatoryVO.java View File

@@ -71,6 +71,10 @@ public class CustomerSignatoryVO implements Serializable {
71 71
      * 户型
72 72
      */
73 73
     private String houseType;
74
+    /**
75
+     * 户型
76
+     */
77
+    private String houseTypeName;
74 78
 
75 79
     /** 房屋信息 */
76 80
     private String houseInfo;

+ 5
- 2
src/main/resources/mapper/TaRecommendCustomerMapper.xml View File

@@ -88,8 +88,11 @@ FROM
88 88
         ta_person a
89 89
         left join ta_channel_person tcp on a.person_id = tcp.person_id
90 90
         left join ta_channel tc on tc.channel_id = tcp.channel_id
91
-        <where>
92
-            a.person_type in in ('channel agent', 'estate agent')
91
+        <where> 1=1
92
+            <if test="personId != null and personId !=''">
93
+                and a.person_id = #{personId}
94
+            </if>
95
+            and a.person_type in ('channel agent', 'estate agent')
93 96
             and a.status >0
94 97
             <if test="name != null and name !=''">
95 98
                 and a.nickname = #{name}

+ 5
- 2
src/main/resources/mapper/xlk/CustomerSignatoryMapper.xml View File

@@ -19,17 +19,19 @@
19 19
             t.dividends_name,
20 20
             t.proportion,
21 21
             t.house_type,
22
+            m.apartment_name as house_type_name,
22 23
             t.house_info,
23 24
             p.`name` as recommend_name,
24 25
             p.tel as recommend_tel,
25
-            p.`name` as realty_consultant_name,
26
-            p.tel as realty_consultant_tel
26
+            pp.`name` as realty_consultant_name,
27
+            pp.tel as realty_consultant_tel
27 28
         FROM
28 29
             xlk_customer_signatory t
29 30
         LEFT JOIN ta_recommend_customer c ON t.customer_id = c.customer_id
30 31
         LEFT JOIN ta_building b on t.building_id = b.building_id
31 32
         LEFT JOIN ta_person p on t.recommend_person = p.person_id
32 33
         LEFT JOIN ta_person pp on t.realty_consultant = pp.person_id
34
+        LEFT JOIN ta_building_apartment m on m.building_id = t.building_id and m.apartment_id = t.house_type
33 35
         WHERE
34 36
         t.org_id = #{orgId}
35 37
         <if test="buildingId != null and buildingId != ''">
@@ -45,5 +47,6 @@
45 47
         <if test="type != null and type != ''">
46 48
             and t.type = #{type}
47 49
         </if>
50
+        ORDER BY t.create_date DESC
48 51
     </select>
49 52
 </mapper>