fuxingfan 3 年前
父节点
当前提交
85fcf27053
共有 29 个文件被更改,包括 1339 次插入0 次删除
  1. 24
    0
      src/main/java/com/yunzhi/marketing/xlk/controller/BuildingChannelController.java
  2. 162
    0
      src/main/java/com/yunzhi/marketing/xlk/controller/CustomerPreparatoryController.java
  3. 162
    0
      src/main/java/com/yunzhi/marketing/xlk/controller/CustomerSignatoryController.java
  4. 162
    0
      src/main/java/com/yunzhi/marketing/xlk/controller/CustomerSubscribeController.java
  5. 162
    0
      src/main/java/com/yunzhi/marketing/xlk/controller/CustomerVisitController.java
  6. 78
    0
      src/main/java/com/yunzhi/marketing/xlk/entity/CustomerPreparatory.java
  7. 113
    0
      src/main/java/com/yunzhi/marketing/xlk/entity/CustomerSignatory.java
  8. 113
    0
      src/main/java/com/yunzhi/marketing/xlk/entity/CustomerSubscribe.java
  9. 83
    0
      src/main/java/com/yunzhi/marketing/xlk/entity/CustomerVisit.java
  10. 9
    0
      src/main/java/com/yunzhi/marketing/xlk/mapper/BuildingChannelMapper.java
  11. 18
    0
      src/main/java/com/yunzhi/marketing/xlk/mapper/CustomerPreparatoryMapper.java
  12. 18
    0
      src/main/java/com/yunzhi/marketing/xlk/mapper/CustomerSignatoryMapper.java
  13. 18
    0
      src/main/java/com/yunzhi/marketing/xlk/mapper/CustomerSubscribeMapper.java
  14. 18
    0
      src/main/java/com/yunzhi/marketing/xlk/mapper/CustomerVisitMapper.java
  15. 8
    0
      src/main/java/com/yunzhi/marketing/xlk/service/IBuildingChannelService.java
  16. 16
    0
      src/main/java/com/yunzhi/marketing/xlk/service/ICustomerPreparatoryService.java
  17. 16
    0
      src/main/java/com/yunzhi/marketing/xlk/service/ICustomerSignatoryService.java
  18. 16
    0
      src/main/java/com/yunzhi/marketing/xlk/service/ICustomerSubscribeService.java
  19. 16
    0
      src/main/java/com/yunzhi/marketing/xlk/service/ICustomerVisitService.java
  20. 17
    0
      src/main/java/com/yunzhi/marketing/xlk/service/impl/BuildingChannelServiceImpl.java
  21. 20
    0
      src/main/java/com/yunzhi/marketing/xlk/service/impl/CustomerPreparatoryServiceImpl.java
  22. 20
    0
      src/main/java/com/yunzhi/marketing/xlk/service/impl/CustomerSignatoryServiceImpl.java
  23. 20
    0
      src/main/java/com/yunzhi/marketing/xlk/service/impl/CustomerSubscribeServiceImpl.java
  24. 20
    0
      src/main/java/com/yunzhi/marketing/xlk/service/impl/CustomerVisitServiceImpl.java
  25. 10
    0
      src/main/resources/mapper/xlk/BuildingChannelMapper.xml
  26. 5
    0
      src/main/resources/mapper/xlk/CustomerPreparatoryMapper.xml
  27. 5
    0
      src/main/resources/mapper/xlk/CustomerSignatoryMapper.xml
  28. 5
    0
      src/main/resources/mapper/xlk/CustomerSubscribeMapper.xml
  29. 5
    0
      src/main/resources/mapper/xlk/CustomerVisitMapper.xml

+ 24
- 0
src/main/java/com/yunzhi/marketing/xlk/controller/BuildingChannelController.java 查看文件

@@ -3,7 +3,10 @@ package com.yunzhi.marketing.xlk.controller;
3 3
 import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
4 4
 import com.yunzhi.marketing.base.BaseController;
5 5
 import com.yunzhi.marketing.base.ResponseBean;
6
+import com.yunzhi.marketing.entity.TaPerson;
7
+import com.yunzhi.marketing.service.ITaPersonService;
6 8
 import com.yunzhi.marketing.xlk.dto.BuildingChannelDTO;
9
+import com.yunzhi.marketing.xlk.dto.MarkingChannelCustomerDTO;
7 10
 import com.yunzhi.marketing.xlk.entity.BuildingChannel;
8 11
 import com.yunzhi.marketing.xlk.service.IBuildingChannelService;
9 12
 import io.swagger.annotations.Api;
@@ -38,6 +41,9 @@ public class BuildingChannelController extends BaseController {
38 41
     @Autowired
39 42
     public IBuildingChannelService iBuildingChannelService;
40 43
 
44
+    @Autowired
45
+    ITaPersonService iTaPersonService;
46
+
41 47
     /**
42 48
      * 保存对象
43 49
      * @param buildingChannelDTO 实体对象
@@ -141,4 +147,22 @@ public class BuildingChannelController extends BaseController {
141 147
         }
142 148
         return responseBean;
143 149
     }
150
+
151
+    /**
152
+     * 获取渠道的楼盘列表
153
+     *
154
+     * @param
155
+     * @return
156
+     */
157
+    @ApiOperation(value = "小哥哥看这里-wx-获取渠道的楼盘列表", notes = "小哥哥看这里-wx-获取渠道的楼盘列表")
158
+    @RequestMapping(value="/wx/buildingChannel/buildings",method= RequestMethod.GET)
159
+    public ResponseBean channelBuildingList(@RequestHeader("authorization") String token, HttpServletRequest request){
160
+        String openid = getOpenId(request);
161
+        List<TaPerson> persons = iTaPersonService.getPersonsByOpenId(openid);
162
+        if (null == persons || persons.size() == 0) {
163
+            return ResponseBean.error("当前账户信息异常, 清除缓存重试", ResponseBean.ERROR_UNAVAILABLE);
164
+        }
165
+        TaPerson person = persons.get(0);
166
+        return iBuildingChannelService.getChannelBuildingList(person);
167
+    }
144 168
 }

+ 162
- 0
src/main/java/com/yunzhi/marketing/xlk/controller/CustomerPreparatoryController.java 查看文件

@@ -0,0 +1,162 @@
1
+package com.yunzhi.marketing.xlk.controller;
2
+
3
+import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
4
+import com.baomidou.mybatisplus.core.metadata.IPage;
5
+import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
6
+import com.yunzhi.marketing.base.BaseController;
7
+import com.yunzhi.marketing.base.ResponseBean;
8
+import com.yunzhi.marketing.xlk.entity.CustomerPreparatory;
9
+import com.yunzhi.marketing.xlk.service.ICustomerPreparatoryService;
10
+import io.swagger.annotations.Api;
11
+import io.swagger.annotations.ApiOperation;
12
+import org.slf4j.Logger;
13
+import org.slf4j.LoggerFactory;
14
+import org.springframework.beans.factory.annotation.Autowired;
15
+import org.springframework.web.bind.annotation.PathVariable;
16
+import org.springframework.web.bind.annotation.RequestBody;
17
+import org.springframework.web.bind.annotation.RequestHeader;
18
+import org.springframework.web.bind.annotation.RequestMapping;
19
+import org.springframework.web.bind.annotation.RequestMethod;
20
+import org.springframework.web.bind.annotation.RequestParam;
21
+import org.springframework.web.bind.annotation.ResponseBody;
22
+import org.springframework.web.bind.annotation.RestController;
23
+
24
+import javax.servlet.http.HttpServletRequest;
25
+
26
+/**
27
+ * <p>
28
+    * 客户认筹单  前端控制器
29
+    * </p>
30
+ *
31
+ * @author jobob
32
+ * @since 2021-07-30
33
+ */
34
+@RestController
35
+@RequestMapping("/api")
36
+@Api(value = "", tags = "xlk-")
37
+public class CustomerPreparatoryController extends BaseController {
38
+
39
+    private final Logger logger = LoggerFactory.getLogger(CustomerPreparatoryController.class);
40
+
41
+    @Autowired
42
+    public ICustomerPreparatoryService iCustomerPreparatoryService;
43
+
44
+
45
+    /**
46
+     * 分页查询列表
47
+     * @param pageNum
48
+     * @param pageSize
49
+     * @return
50
+     */
51
+    @ApiOperation(value = "", notes = "")
52
+    @RequestMapping(value="/customerPreparatory",method= RequestMethod.GET)
53
+    public ResponseBean customerPreparatoryList(@RequestParam(value ="pageNum",defaultValue = "1") Integer pageNum,
54
+                                                @RequestParam(value ="pageSize",defaultValue = "10") Integer pageSize,
55
+                                                @RequestHeader("authorization") String token, HttpServletRequest request){
56
+        ResponseBean responseBean = new ResponseBean();
57
+        try {
58
+            //使用分页插件
59
+		    IPage<CustomerPreparatory> pg = new Page<>(pageNum, pageSize);
60
+            LambdaQueryWrapper<CustomerPreparatory> queryWrapper = new LambdaQueryWrapper<>();
61
+            queryWrapper.eq(CustomerPreparatory::getOrgId,getOrgId(request));
62
+            queryWrapper.orderByDesc(CustomerPreparatory::getCreateDate);
63
+
64
+            IPage<CustomerPreparatory> result = iCustomerPreparatoryService.page(pg, queryWrapper);
65
+            responseBean.addSuccess(result);
66
+        }catch (Exception e){
67
+            e.printStackTrace();
68
+            logger.error("customerPreparatoryList -=- {}",e.toString());
69
+            responseBean.addError(e.getMessage());
70
+        }
71
+        return responseBean;
72
+    }
73
+
74
+    /**
75
+     * 保存对象
76
+     * @param customerPreparatory 实体对象
77
+     * @return
78
+     */
79
+    @ApiOperation(value = "", notes = "")
80
+    @RequestMapping(value="/customerPreparatory",method= RequestMethod.POST)
81
+    public ResponseBean customerPreparatoryAdd(@RequestBody CustomerPreparatory customerPreparatory, @RequestHeader("authorization") String token, HttpServletRequest request){
82
+        ResponseBean responseBean = new ResponseBean();
83
+        try {
84
+            if (iCustomerPreparatoryService.save(customerPreparatory)){
85
+                responseBean.addSuccess(customerPreparatory);
86
+            }else {
87
+                responseBean.addError("fail");
88
+            }
89
+        }catch (Exception e){
90
+            e.printStackTrace();
91
+            logger.error("customerPreparatoryAdd -=- {}",e.toString());
92
+            responseBean.addError(e.getMessage());
93
+        }
94
+        return responseBean;
95
+    }
96
+
97
+    /**
98
+     * 根据id删除对象
99
+     * @param id  实体ID
100
+     */
101
+    @ApiOperation(value = "", notes = "")
102
+    @ResponseBody
103
+    @RequestMapping(value="/customerPreparatory/{id}", method= RequestMethod.DELETE)
104
+    public ResponseBean customerPreparatoryDelete(@PathVariable String id, @RequestHeader("authorization") String token, HttpServletRequest request){
105
+        ResponseBean responseBean = new ResponseBean();
106
+        try {
107
+            if(iCustomerPreparatoryService.removeById(id)){
108
+                responseBean.addSuccess("success");
109
+            }else {
110
+                responseBean.addError("fail");
111
+            }
112
+        }catch (Exception e){
113
+            e.printStackTrace();
114
+            logger.error("customerPreparatoryDelete -=- {}",e.toString());
115
+            responseBean.addError(e.getMessage());
116
+        }
117
+        return responseBean;
118
+    }
119
+
120
+    /**
121
+     * 修改对象
122
+     * @param id  实体ID
123
+     * @param customerPreparatory 实体对象
124
+     * @return
125
+     */
126
+    @ApiOperation(value = "", notes = "")
127
+    @RequestMapping(value="/customerPreparatory/{id}",method= RequestMethod.PUT)
128
+    public ResponseBean customerPreparatoryUpdate(@PathVariable String id,
129
+                                                  @RequestBody CustomerPreparatory customerPreparatory, @RequestHeader("authorization") String token, HttpServletRequest request){
130
+        ResponseBean responseBean = new ResponseBean();
131
+        try {
132
+            if (iCustomerPreparatoryService.updateById(customerPreparatory)){
133
+                responseBean.addSuccess(customerPreparatory);
134
+            }else {
135
+                responseBean.addError("fail");
136
+            }
137
+        }catch (Exception e){
138
+            e.printStackTrace();
139
+            logger.error("customerPreparatoryUpdate -=- {}",e.toString());
140
+            responseBean.addError(e.getMessage());
141
+        }
142
+        return responseBean;
143
+    }
144
+
145
+    /**
146
+     * 根据id查询对象
147
+     * @param id  实体ID
148
+     */
149
+    @ApiOperation(value = "", notes = "")
150
+    @RequestMapping(value="/customerPreparatory/{id}",method= RequestMethod.GET)
151
+    public ResponseBean customerPreparatoryGet(@PathVariable String id, @RequestHeader("authorization") String token, HttpServletRequest request){
152
+        ResponseBean responseBean = new ResponseBean();
153
+        try {
154
+            responseBean.addSuccess(iCustomerPreparatoryService.getById(id));
155
+        }catch (Exception e){
156
+            e.printStackTrace();
157
+            logger.error("customerPreparatoryDelete -=- {}",e.toString());
158
+            responseBean.addError(e.getMessage());
159
+        }
160
+        return responseBean;
161
+    }
162
+}

+ 162
- 0
src/main/java/com/yunzhi/marketing/xlk/controller/CustomerSignatoryController.java 查看文件

@@ -0,0 +1,162 @@
1
+package com.yunzhi.marketing.xlk.controller;
2
+
3
+import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
4
+import com.baomidou.mybatisplus.core.metadata.IPage;
5
+import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
6
+import com.yunzhi.marketing.base.BaseController;
7
+import com.yunzhi.marketing.base.ResponseBean;
8
+import com.yunzhi.marketing.xlk.entity.CustomerSignatory;
9
+import com.yunzhi.marketing.xlk.service.ICustomerSignatoryService;
10
+import io.swagger.annotations.Api;
11
+import io.swagger.annotations.ApiOperation;
12
+import org.slf4j.Logger;
13
+import org.slf4j.LoggerFactory;
14
+import org.springframework.beans.factory.annotation.Autowired;
15
+import org.springframework.web.bind.annotation.PathVariable;
16
+import org.springframework.web.bind.annotation.RequestBody;
17
+import org.springframework.web.bind.annotation.RequestHeader;
18
+import org.springframework.web.bind.annotation.RequestMapping;
19
+import org.springframework.web.bind.annotation.RequestMethod;
20
+import org.springframework.web.bind.annotation.RequestParam;
21
+import org.springframework.web.bind.annotation.ResponseBody;
22
+import org.springframework.web.bind.annotation.RestController;
23
+
24
+import javax.servlet.http.HttpServletRequest;
25
+
26
+/**
27
+ * <p>
28
+    * 客户签约单  前端控制器
29
+    * </p>
30
+ *
31
+ * @author jobob
32
+ * @since 2021-07-30
33
+ */
34
+@RestController
35
+@RequestMapping("/api")
36
+@Api(value = "", tags = "xlk-")
37
+public class CustomerSignatoryController extends BaseController {
38
+
39
+    private final Logger logger = LoggerFactory.getLogger(CustomerSignatoryController.class);
40
+
41
+    @Autowired
42
+    public ICustomerSignatoryService iCustomerSignatoryService;
43
+
44
+
45
+    /**
46
+     * 分页查询列表
47
+     * @param pageNum
48
+     * @param pageSize
49
+     * @return
50
+     */
51
+    @ApiOperation(value = "", notes = "")
52
+    @RequestMapping(value="/customerSignatory",method= RequestMethod.GET)
53
+    public ResponseBean customerSignatoryList(@RequestParam(value ="pageNum",defaultValue = "1") Integer pageNum,
54
+                                              @RequestParam(value ="pageSize",defaultValue = "10") Integer pageSize,
55
+                                              @RequestHeader("authorization") String token, HttpServletRequest request){
56
+        ResponseBean responseBean = new ResponseBean();
57
+        try {
58
+            //使用分页插件
59
+		    IPage<CustomerSignatory> pg = new Page<>(pageNum, pageSize);
60
+            LambdaQueryWrapper<CustomerSignatory> queryWrapper = new LambdaQueryWrapper<>();
61
+            queryWrapper.eq(CustomerSignatory::getOrgId,getOrgId(request));
62
+            queryWrapper.orderByDesc(CustomerSignatory::getCreateDate);
63
+
64
+            IPage<CustomerSignatory> result = iCustomerSignatoryService.page(pg, queryWrapper);
65
+            responseBean.addSuccess(result);
66
+        }catch (Exception e){
67
+            e.printStackTrace();
68
+            logger.error("customerSignatoryList -=- {}",e.toString());
69
+            responseBean.addError(e.getMessage());
70
+        }
71
+        return responseBean;
72
+    }
73
+
74
+    /**
75
+     * 保存对象
76
+     * @param customerSignatory 实体对象
77
+     * @return
78
+     */
79
+    @ApiOperation(value = "", notes = "")
80
+    @RequestMapping(value="/customerSignatory",method= RequestMethod.POST)
81
+    public ResponseBean customerSignatoryAdd(@RequestBody CustomerSignatory customerSignatory, @RequestHeader("authorization") String token, HttpServletRequest request){
82
+        ResponseBean responseBean = new ResponseBean();
83
+        try {
84
+            if (iCustomerSignatoryService.save(customerSignatory)){
85
+                responseBean.addSuccess(customerSignatory);
86
+            }else {
87
+                responseBean.addError("fail");
88
+            }
89
+        }catch (Exception e){
90
+            e.printStackTrace();
91
+            logger.error("customerSignatoryAdd -=- {}",e.toString());
92
+            responseBean.addError(e.getMessage());
93
+        }
94
+        return responseBean;
95
+    }
96
+
97
+    /**
98
+     * 根据id删除对象
99
+     * @param id  实体ID
100
+     */
101
+    @ApiOperation(value = "", notes = "")
102
+    @ResponseBody
103
+    @RequestMapping(value="/customerSignatory/{id}", method= RequestMethod.DELETE)
104
+    public ResponseBean customerSignatoryDelete(@PathVariable String id, @RequestHeader("authorization") String token, HttpServletRequest request){
105
+        ResponseBean responseBean = new ResponseBean();
106
+        try {
107
+            if(iCustomerSignatoryService.removeById(id)){
108
+                responseBean.addSuccess("success");
109
+            }else {
110
+                responseBean.addError("fail");
111
+            }
112
+        }catch (Exception e){
113
+            e.printStackTrace();
114
+            logger.error("customerSignatoryDelete -=- {}",e.toString());
115
+            responseBean.addError(e.getMessage());
116
+        }
117
+        return responseBean;
118
+    }
119
+
120
+    /**
121
+     * 修改对象
122
+     * @param id  实体ID
123
+     * @param customerSignatory 实体对象
124
+     * @return
125
+     */
126
+    @ApiOperation(value = "", notes = "")
127
+    @RequestMapping(value="/customerSignatory/{id}",method= RequestMethod.PUT)
128
+    public ResponseBean customerSignatoryUpdate(@PathVariable String id,
129
+                                                @RequestBody CustomerSignatory customerSignatory, @RequestHeader("authorization") String token, HttpServletRequest request){
130
+        ResponseBean responseBean = new ResponseBean();
131
+        try {
132
+            if (iCustomerSignatoryService.updateById(customerSignatory)){
133
+                responseBean.addSuccess(customerSignatory);
134
+            }else {
135
+                responseBean.addError("fail");
136
+            }
137
+        }catch (Exception e){
138
+            e.printStackTrace();
139
+            logger.error("customerSignatoryUpdate -=- {}",e.toString());
140
+            responseBean.addError(e.getMessage());
141
+        }
142
+        return responseBean;
143
+    }
144
+
145
+    /**
146
+     * 根据id查询对象
147
+     * @param id  实体ID
148
+     */
149
+    @ApiOperation(value = "", notes = "")
150
+    @RequestMapping(value="/customerSignatory/{id}",method= RequestMethod.GET)
151
+    public ResponseBean customerSignatoryGet(@PathVariable String id, @RequestHeader("authorization") String token, HttpServletRequest request){
152
+        ResponseBean responseBean = new ResponseBean();
153
+        try {
154
+            responseBean.addSuccess(iCustomerSignatoryService.getById(id));
155
+        }catch (Exception e){
156
+            e.printStackTrace();
157
+            logger.error("customerSignatoryDelete -=- {}",e.toString());
158
+            responseBean.addError(e.getMessage());
159
+        }
160
+        return responseBean;
161
+    }
162
+}

+ 162
- 0
src/main/java/com/yunzhi/marketing/xlk/controller/CustomerSubscribeController.java 查看文件

@@ -0,0 +1,162 @@
1
+package com.yunzhi.marketing.xlk.controller;
2
+
3
+import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
4
+import com.baomidou.mybatisplus.core.metadata.IPage;
5
+import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
6
+import com.yunzhi.marketing.base.BaseController;
7
+import com.yunzhi.marketing.base.ResponseBean;
8
+import com.yunzhi.marketing.xlk.entity.CustomerSubscribe;
9
+import com.yunzhi.marketing.xlk.service.ICustomerSubscribeService;
10
+import io.swagger.annotations.Api;
11
+import io.swagger.annotations.ApiOperation;
12
+import org.slf4j.Logger;
13
+import org.slf4j.LoggerFactory;
14
+import org.springframework.beans.factory.annotation.Autowired;
15
+import org.springframework.web.bind.annotation.PathVariable;
16
+import org.springframework.web.bind.annotation.RequestBody;
17
+import org.springframework.web.bind.annotation.RequestHeader;
18
+import org.springframework.web.bind.annotation.RequestMapping;
19
+import org.springframework.web.bind.annotation.RequestMethod;
20
+import org.springframework.web.bind.annotation.RequestParam;
21
+import org.springframework.web.bind.annotation.ResponseBody;
22
+import org.springframework.web.bind.annotation.RestController;
23
+
24
+import javax.servlet.http.HttpServletRequest;
25
+
26
+/**
27
+ * <p>
28
+    * 客户认购单  前端控制器
29
+    * </p>
30
+ *
31
+ * @author jobob
32
+ * @since 2021-07-30
33
+ */
34
+@RestController
35
+@RequestMapping("/api")
36
+@Api(value = "", tags = "xlk-")
37
+public class CustomerSubscribeController extends BaseController {
38
+
39
+    private final Logger logger = LoggerFactory.getLogger(CustomerSubscribeController.class);
40
+
41
+    @Autowired
42
+    public ICustomerSubscribeService iCustomerSubscribeService;
43
+
44
+
45
+    /**
46
+     * 分页查询列表
47
+     * @param pageNum
48
+     * @param pageSize
49
+     * @return
50
+     */
51
+    @ApiOperation(value = "", notes = "")
52
+    @RequestMapping(value="/customerSubscribe",method= RequestMethod.GET)
53
+    public ResponseBean customerSubscribeList(@RequestParam(value ="pageNum",defaultValue = "1") Integer pageNum,
54
+                                              @RequestParam(value ="pageSize",defaultValue = "10") Integer pageSize,
55
+                                              @RequestHeader("authorization") String token, HttpServletRequest request){
56
+        ResponseBean responseBean = new ResponseBean();
57
+        try {
58
+            //使用分页插件
59
+		    IPage<CustomerSubscribe> pg = new Page<>(pageNum, pageSize);
60
+            LambdaQueryWrapper<CustomerSubscribe> queryWrapper = new LambdaQueryWrapper<>();
61
+            queryWrapper.eq(CustomerSubscribe::getOrgId,getOrgId(request));
62
+            queryWrapper.orderByDesc(CustomerSubscribe::getCreateDate);
63
+
64
+            IPage<CustomerSubscribe> result = iCustomerSubscribeService.page(pg, queryWrapper);
65
+            responseBean.addSuccess(result);
66
+        }catch (Exception e){
67
+            e.printStackTrace();
68
+            logger.error("customerSubscribeList -=- {}",e.toString());
69
+            responseBean.addError(e.getMessage());
70
+        }
71
+        return responseBean;
72
+    }
73
+
74
+    /**
75
+     * 保存对象
76
+     * @param customerSubscribe 实体对象
77
+     * @return
78
+     */
79
+    @ApiOperation(value = "", notes = "")
80
+    @RequestMapping(value="/customerSubscribe",method= RequestMethod.POST)
81
+    public ResponseBean customerSubscribeAdd(@RequestBody CustomerSubscribe customerSubscribe, @RequestHeader("authorization") String token, HttpServletRequest request){
82
+        ResponseBean responseBean = new ResponseBean();
83
+        try {
84
+            if (iCustomerSubscribeService.save(customerSubscribe)){
85
+                responseBean.addSuccess(customerSubscribe);
86
+            }else {
87
+                responseBean.addError("fail");
88
+            }
89
+        }catch (Exception e){
90
+            e.printStackTrace();
91
+            logger.error("customerSubscribeAdd -=- {}",e.toString());
92
+            responseBean.addError(e.getMessage());
93
+        }
94
+        return responseBean;
95
+    }
96
+
97
+    /**
98
+     * 根据id删除对象
99
+     * @param id  实体ID
100
+     */
101
+    @ApiOperation(value = "", notes = "")
102
+    @ResponseBody
103
+    @RequestMapping(value="/customerSubscribe/{id}", method= RequestMethod.DELETE)
104
+    public ResponseBean customerSubscribeDelete(@PathVariable String id, @RequestHeader("authorization") String token, HttpServletRequest request){
105
+        ResponseBean responseBean = new ResponseBean();
106
+        try {
107
+            if(iCustomerSubscribeService.removeById(id)){
108
+                responseBean.addSuccess("success");
109
+            }else {
110
+                responseBean.addError("fail");
111
+            }
112
+        }catch (Exception e){
113
+            e.printStackTrace();
114
+            logger.error("customerSubscribeDelete -=- {}",e.toString());
115
+            responseBean.addError(e.getMessage());
116
+        }
117
+        return responseBean;
118
+    }
119
+
120
+    /**
121
+     * 修改对象
122
+     * @param id  实体ID
123
+     * @param customerSubscribe 实体对象
124
+     * @return
125
+     */
126
+    @ApiOperation(value = "", notes = "")
127
+    @RequestMapping(value="/customerSubscribe/{id}",method= RequestMethod.PUT)
128
+    public ResponseBean customerSubscribeUpdate(@PathVariable String id,
129
+                                                @RequestBody CustomerSubscribe customerSubscribe, @RequestHeader("authorization") String token, HttpServletRequest request){
130
+        ResponseBean responseBean = new ResponseBean();
131
+        try {
132
+            if (iCustomerSubscribeService.updateById(customerSubscribe)){
133
+                responseBean.addSuccess(customerSubscribe);
134
+            }else {
135
+                responseBean.addError("fail");
136
+            }
137
+        }catch (Exception e){
138
+            e.printStackTrace();
139
+            logger.error("customerSubscribeUpdate -=- {}",e.toString());
140
+            responseBean.addError(e.getMessage());
141
+        }
142
+        return responseBean;
143
+    }
144
+
145
+    /**
146
+     * 根据id查询对象
147
+     * @param id  实体ID
148
+     */
149
+    @ApiOperation(value = "", notes = "")
150
+    @RequestMapping(value="/customerSubscribe/{id}",method= RequestMethod.GET)
151
+    public ResponseBean customerSubscribeGet(@PathVariable String id, @RequestHeader("authorization") String token, HttpServletRequest request){
152
+        ResponseBean responseBean = new ResponseBean();
153
+        try {
154
+            responseBean.addSuccess(iCustomerSubscribeService.getById(id));
155
+        }catch (Exception e){
156
+            e.printStackTrace();
157
+            logger.error("customerSubscribeDelete -=- {}",e.toString());
158
+            responseBean.addError(e.getMessage());
159
+        }
160
+        return responseBean;
161
+    }
162
+}

+ 162
- 0
src/main/java/com/yunzhi/marketing/xlk/controller/CustomerVisitController.java 查看文件

@@ -0,0 +1,162 @@
1
+package com.yunzhi.marketing.xlk.controller;
2
+
3
+import com.baomidou.mybatisplus.core.conditions.query.LambdaQueryWrapper;
4
+import com.baomidou.mybatisplus.core.metadata.IPage;
5
+import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
6
+import com.yunzhi.marketing.base.BaseController;
7
+import com.yunzhi.marketing.base.ResponseBean;
8
+import com.yunzhi.marketing.xlk.entity.CustomerVisit;
9
+import com.yunzhi.marketing.xlk.service.ICustomerVisitService;
10
+import io.swagger.annotations.Api;
11
+import io.swagger.annotations.ApiOperation;
12
+import org.slf4j.Logger;
13
+import org.slf4j.LoggerFactory;
14
+import org.springframework.beans.factory.annotation.Autowired;
15
+import org.springframework.web.bind.annotation.PathVariable;
16
+import org.springframework.web.bind.annotation.RequestBody;
17
+import org.springframework.web.bind.annotation.RequestHeader;
18
+import org.springframework.web.bind.annotation.RequestMapping;
19
+import org.springframework.web.bind.annotation.RequestMethod;
20
+import org.springframework.web.bind.annotation.RequestParam;
21
+import org.springframework.web.bind.annotation.ResponseBody;
22
+import org.springframework.web.bind.annotation.RestController;
23
+
24
+import javax.servlet.http.HttpServletRequest;
25
+
26
+/**
27
+ * <p>
28
+    * 客户到访单  前端控制器
29
+    * </p>
30
+ *
31
+ * @author jobob
32
+ * @since 2021-07-30
33
+ */
34
+@RestController
35
+@RequestMapping("/api")
36
+@Api(value = "", tags = "xlk-")
37
+public class CustomerVisitController extends BaseController {
38
+
39
+    private final Logger logger = LoggerFactory.getLogger(CustomerVisitController.class);
40
+
41
+    @Autowired
42
+    public ICustomerVisitService iCustomerVisitService;
43
+
44
+
45
+    /**
46
+     * 分页查询列表
47
+     * @param pageNum
48
+     * @param pageSize
49
+     * @return
50
+     */
51
+    @ApiOperation(value = "", notes = "")
52
+    @RequestMapping(value="/customerVisit",method= RequestMethod.GET)
53
+    public ResponseBean customerVisitList(@RequestParam(value ="pageNum",defaultValue = "1") Integer pageNum,
54
+                                          @RequestParam(value ="pageSize",defaultValue = "10") Integer pageSize,
55
+                                          @RequestHeader("authorization") String token, HttpServletRequest request){
56
+        ResponseBean responseBean = new ResponseBean();
57
+        try {
58
+            //使用分页插件
59
+		    IPage<CustomerVisit> pg = new Page<>(pageNum, pageSize);
60
+            LambdaQueryWrapper<CustomerVisit> queryWrapper = new LambdaQueryWrapper<>();
61
+            queryWrapper.eq(CustomerVisit::getOrgId,getOrgId(request));
62
+            queryWrapper.orderByDesc(CustomerVisit::getCreateDate);
63
+
64
+            IPage<CustomerVisit> result = iCustomerVisitService.page(pg, queryWrapper);
65
+            responseBean.addSuccess(result);
66
+        }catch (Exception e){
67
+            e.printStackTrace();
68
+            logger.error("customerVisitList -=- {}",e.toString());
69
+            responseBean.addError(e.getMessage());
70
+        }
71
+        return responseBean;
72
+    }
73
+
74
+    /**
75
+     * 保存对象
76
+     * @param customerVisit 实体对象
77
+     * @return
78
+     */
79
+    @ApiOperation(value = "", notes = "")
80
+    @RequestMapping(value="/customerVisit",method= RequestMethod.POST)
81
+    public ResponseBean customerVisitAdd(@RequestBody CustomerVisit customerVisit, @RequestHeader("authorization") String token, HttpServletRequest request){
82
+        ResponseBean responseBean = new ResponseBean();
83
+        try {
84
+            if (iCustomerVisitService.save(customerVisit)){
85
+                responseBean.addSuccess(customerVisit);
86
+            }else {
87
+                responseBean.addError("fail");
88
+            }
89
+        }catch (Exception e){
90
+            e.printStackTrace();
91
+            logger.error("customerVisitAdd -=- {}",e.toString());
92
+            responseBean.addError(e.getMessage());
93
+        }
94
+        return responseBean;
95
+    }
96
+
97
+    /**
98
+     * 根据id删除对象
99
+     * @param id  实体ID
100
+     */
101
+    @ApiOperation(value = "", notes = "")
102
+    @ResponseBody
103
+    @RequestMapping(value="/customerVisit/{id}", method= RequestMethod.DELETE)
104
+    public ResponseBean customerVisitDelete(@PathVariable String id, @RequestHeader("authorization") String token, HttpServletRequest request){
105
+        ResponseBean responseBean = new ResponseBean();
106
+        try {
107
+            if(iCustomerVisitService.removeById(id)){
108
+                responseBean.addSuccess("success");
109
+            }else {
110
+                responseBean.addError("fail");
111
+            }
112
+        }catch (Exception e){
113
+            e.printStackTrace();
114
+            logger.error("customerVisitDelete -=- {}",e.toString());
115
+            responseBean.addError(e.getMessage());
116
+        }
117
+        return responseBean;
118
+    }
119
+
120
+    /**
121
+     * 修改对象
122
+     * @param id  实体ID
123
+     * @param customerVisit 实体对象
124
+     * @return
125
+     */
126
+    @ApiOperation(value = "", notes = "")
127
+    @RequestMapping(value="/customerVisit/{id}",method= RequestMethod.PUT)
128
+    public ResponseBean customerVisitUpdate(@PathVariable String id,
129
+                                            @RequestBody CustomerVisit customerVisit, @RequestHeader("authorization") String token, HttpServletRequest request){
130
+        ResponseBean responseBean = new ResponseBean();
131
+        try {
132
+            if (iCustomerVisitService.updateById(customerVisit)){
133
+                responseBean.addSuccess(customerVisit);
134
+            }else {
135
+                responseBean.addError("fail");
136
+            }
137
+        }catch (Exception e){
138
+            e.printStackTrace();
139
+            logger.error("customerVisitUpdate -=- {}",e.toString());
140
+            responseBean.addError(e.getMessage());
141
+        }
142
+        return responseBean;
143
+    }
144
+
145
+    /**
146
+     * 根据id查询对象
147
+     * @param id  实体ID
148
+     */
149
+    @ApiOperation(value = "", notes = "")
150
+    @RequestMapping(value="/customerVisit/{id}",method= RequestMethod.GET)
151
+    public ResponseBean customerVisitGet(@PathVariable String id, @RequestHeader("authorization") String token, HttpServletRequest request){
152
+        ResponseBean responseBean = new ResponseBean();
153
+        try {
154
+            responseBean.addSuccess(iCustomerVisitService.getById(id));
155
+        }catch (Exception e){
156
+            e.printStackTrace();
157
+            logger.error("customerVisitDelete -=- {}",e.toString());
158
+            responseBean.addError(e.getMessage());
159
+        }
160
+        return responseBean;
161
+    }
162
+}

+ 78
- 0
src/main/java/com/yunzhi/marketing/xlk/entity/CustomerPreparatory.java 查看文件

@@ -0,0 +1,78 @@
1
+package com.yunzhi.marketing.xlk.entity;
2
+
3
+import com.baomidou.mybatisplus.annotation.TableName;
4
+import lombok.Data;
5
+import lombok.EqualsAndHashCode;
6
+import lombok.experimental.Accessors;
7
+
8
+import java.io.Serializable;
9
+import java.time.LocalDateTime;
10
+
11
+/**
12
+ * <p>
13
+ * 客户认筹单 
14
+ * </p>
15
+ *
16
+ * @author jobob
17
+ * @since 2021-07-30
18
+ */
19
+@Data
20
+@EqualsAndHashCode(callSuper = false)
21
+@Accessors(chain = true)
22
+@TableName("xlk_customer_preparatory")
23
+public class CustomerPreparatory implements Serializable {
24
+
25
+    private static final long serialVersionUID = 1L;
26
+
27
+    /**
28
+     * 客户认筹id
29
+     */
30
+    private String customerPreparatoryId;
31
+
32
+    /**
33
+     * 客户id
34
+     */
35
+    private String customerId;
36
+
37
+    /**
38
+     * 客户姓名
39
+     */
40
+    private String name;
41
+
42
+    /**
43
+     * 推荐人(归属渠道)
44
+     */
45
+    private String recommendPerson;
46
+
47
+    /**
48
+     * 推荐人姓名(归属渠道)
49
+     */
50
+    private String recommendName;
51
+
52
+    /**
53
+     * 内场接待(置业顾问)
54
+     */
55
+    private String realtyConsultant;
56
+
57
+    /**
58
+     * 内场接待(置业顾问)姓名
59
+     */
60
+    private String realtyConsultantName;
61
+
62
+    /**
63
+     * 创建时间
64
+     */
65
+    private LocalDateTime createDate;
66
+
67
+    /**
68
+     * 备注
69
+     */
70
+    private String remark;
71
+
72
+    /**
73
+     * 公司id
74
+     */
75
+    private Integer orgId;
76
+
77
+
78
+}

+ 113
- 0
src/main/java/com/yunzhi/marketing/xlk/entity/CustomerSignatory.java 查看文件

@@ -0,0 +1,113 @@
1
+package com.yunzhi.marketing.xlk.entity;
2
+
3
+import com.baomidou.mybatisplus.annotation.TableName;
4
+import lombok.Data;
5
+import lombok.EqualsAndHashCode;
6
+import lombok.experimental.Accessors;
7
+
8
+import java.io.Serializable;
9
+import java.time.LocalDateTime;
10
+
11
+/**
12
+ * <p>
13
+ * 客户签约单 
14
+ * </p>
15
+ *
16
+ * @author jobob
17
+ * @since 2021-07-30
18
+ */
19
+@Data
20
+@EqualsAndHashCode(callSuper = false)
21
+@Accessors(chain = true)
22
+@TableName("xlk_customer_signatory")
23
+public class CustomerSignatory implements Serializable {
24
+
25
+    private static final long serialVersionUID = 1L;
26
+
27
+    /**
28
+     * 主键
29
+     */
30
+    private String customerSignatoryId;
31
+
32
+    /**
33
+     * 客户id
34
+     */
35
+    private String customerId;
36
+
37
+    /**
38
+     * 客户姓名
39
+     */
40
+    private String name;
41
+
42
+    /**
43
+     * 推荐人(归属渠道)
44
+     */
45
+    private String recommendPerson;
46
+
47
+    /**
48
+     * 推荐人姓名(归属渠道)
49
+     */
50
+    private String recommendName;
51
+
52
+    /**
53
+     * 内场接待(置业顾问)
54
+     */
55
+    private String realtyConsultant;
56
+
57
+    /**
58
+     * 内场接待(置业顾问)姓名
59
+     */
60
+    private String realtyConsultantName;
61
+
62
+    /**
63
+     * 创建时间
64
+     */
65
+    private LocalDateTime createDate;
66
+
67
+    /**
68
+     * 备注
69
+     */
70
+    private String remark;
71
+
72
+    /**
73
+     * 公司id
74
+     */
75
+    private Integer orgId;
76
+
77
+    /**
78
+     * 业绩分成人
79
+     */
80
+    private String dividendsName;
81
+
82
+    /**
83
+     * 比例
84
+     */
85
+    private String proportion;
86
+
87
+    /**
88
+     * 户型
89
+     */
90
+    private String houseType;
91
+
92
+    /**
93
+     * 栋
94
+     */
95
+    private String ridgepole;
96
+
97
+    /**
98
+     * 单元
99
+     */
100
+    private String unit;
101
+
102
+    /**
103
+     * 室
104
+     */
105
+    private String room;
106
+
107
+    /**
108
+     * 金额
109
+     */
110
+    private String price;
111
+
112
+
113
+}

+ 113
- 0
src/main/java/com/yunzhi/marketing/xlk/entity/CustomerSubscribe.java 查看文件

@@ -0,0 +1,113 @@
1
+package com.yunzhi.marketing.xlk.entity;
2
+
3
+import com.baomidou.mybatisplus.annotation.TableName;
4
+import lombok.Data;
5
+import lombok.EqualsAndHashCode;
6
+import lombok.experimental.Accessors;
7
+
8
+import java.io.Serializable;
9
+import java.time.LocalDateTime;
10
+
11
+/**
12
+ * <p>
13
+ * 客户认购单 
14
+ * </p>
15
+ *
16
+ * @author jobob
17
+ * @since 2021-07-30
18
+ */
19
+@Data
20
+@EqualsAndHashCode(callSuper = false)
21
+@Accessors(chain = true)
22
+@TableName("xlk_customer_subscribe")
23
+public class CustomerSubscribe implements Serializable {
24
+
25
+    private static final long serialVersionUID = 1L;
26
+
27
+    /**
28
+     * 主键
29
+     */
30
+    private String customerSubscribeId;
31
+
32
+    /**
33
+     * 客户id
34
+     */
35
+    private String customerId;
36
+
37
+    /**
38
+     * 客户姓名
39
+     */
40
+    private String name;
41
+
42
+    /**
43
+     * 推荐人(归属渠道)
44
+     */
45
+    private String recommendPerson;
46
+
47
+    /**
48
+     * 推荐人姓名(归属渠道)
49
+     */
50
+    private String recommendName;
51
+
52
+    /**
53
+     * 内场接待(置业顾问)
54
+     */
55
+    private String realtyConsultant;
56
+
57
+    /**
58
+     * 内场接待(置业顾问)姓名
59
+     */
60
+    private String realtyConsultantName;
61
+
62
+    /**
63
+     * 创建时间
64
+     */
65
+    private LocalDateTime createDate;
66
+
67
+    /**
68
+     * 备注
69
+     */
70
+    private String remark;
71
+
72
+    /**
73
+     * 公司id
74
+     */
75
+    private Integer orgId;
76
+
77
+    /**
78
+     * 业绩分成人
79
+     */
80
+    private String dividendsName;
81
+
82
+    /**
83
+     * 比例
84
+     */
85
+    private String proportion;
86
+
87
+    /**
88
+     * 户型
89
+     */
90
+    private String houseType;
91
+
92
+    /**
93
+     * 栋
94
+     */
95
+    private String ridgepole;
96
+
97
+    /**
98
+     * 单元
99
+     */
100
+    private String unit;
101
+
102
+    /**
103
+     * 室
104
+     */
105
+    private String room;
106
+
107
+    /**
108
+     * 金额
109
+     */
110
+    private String price;
111
+
112
+
113
+}

+ 83
- 0
src/main/java/com/yunzhi/marketing/xlk/entity/CustomerVisit.java 查看文件

@@ -0,0 +1,83 @@
1
+package com.yunzhi.marketing.xlk.entity;
2
+
3
+import com.baomidou.mybatisplus.annotation.TableName;
4
+import lombok.Data;
5
+import lombok.EqualsAndHashCode;
6
+import lombok.experimental.Accessors;
7
+
8
+import java.io.Serializable;
9
+import java.time.LocalDateTime;
10
+
11
+/**
12
+ * <p>
13
+ * 客户到访单 
14
+ * </p>
15
+ *
16
+ * @author jobob
17
+ * @since 2021-07-30
18
+ */
19
+@Data
20
+@EqualsAndHashCode(callSuper = false)
21
+@Accessors(chain = true)
22
+@TableName("xlk_customer_visit")
23
+public class CustomerVisit implements Serializable {
24
+
25
+    private static final long serialVersionUID = 1L;
26
+
27
+    /**
28
+     * 客户到访id
29
+     */
30
+    private String customerVisitId;
31
+
32
+    /**
33
+     * 客户id
34
+     */
35
+    private String customerId;
36
+
37
+    /**
38
+     * 客户姓名
39
+     */
40
+    private String name;
41
+
42
+    /**
43
+     * 推荐人(归属渠道)
44
+     */
45
+    private String recommendPerson;
46
+
47
+    /**
48
+     * 推荐人姓名(归属渠道)
49
+     */
50
+    private String recommendName;
51
+
52
+    /**
53
+     * 内场接待(置业顾问)
54
+     */
55
+    private String realtyConsultant;
56
+
57
+    /**
58
+     * 内场接待(置业顾问)姓名
59
+     */
60
+    private String realtyConsultantName;
61
+
62
+    /**
63
+     * 创建时间
64
+     */
65
+    private LocalDateTime createDate;
66
+
67
+    /**
68
+     * 到访照片
69
+     */
70
+    private String imageUrl;
71
+
72
+    /**
73
+     * 备注
74
+     */
75
+    private String remark;
76
+
77
+    /**
78
+     * 公司id
79
+     */
80
+    private Integer orgId;
81
+
82
+
83
+}

+ 9
- 0
src/main/java/com/yunzhi/marketing/xlk/mapper/BuildingChannelMapper.java 查看文件

@@ -1,9 +1,12 @@
1 1
 package com.yunzhi.marketing.xlk.mapper;
2 2
 
3 3
 import com.baomidou.mybatisplus.core.mapper.BaseMapper;
4
+import com.yunzhi.marketing.entity.TaBuilding;
4 5
 import com.yunzhi.marketing.xlk.entity.BuildingChannel;
5 6
 import org.apache.ibatis.annotations.Mapper;
6 7
 
8
+import java.util.List;
9
+
7 10
 /**
8 11
  * <p>
9 12
  * 楼盘渠道表  Mapper 接口
@@ -15,4 +18,10 @@ import org.apache.ibatis.annotations.Mapper;
15 18
 @Mapper
16 19
 public interface BuildingChannelMapper extends BaseMapper<BuildingChannel> {
17 20
 
21
+    /**
22
+     * 获取当前登录人的渠道building
23
+     * @param personId
24
+     * @return
25
+     */
26
+    List<TaBuilding> getChannelBuildingList(String personId);
18 27
 }

+ 18
- 0
src/main/java/com/yunzhi/marketing/xlk/mapper/CustomerPreparatoryMapper.java 查看文件

@@ -0,0 +1,18 @@
1
+package com.yunzhi.marketing.xlk.mapper;
2
+
3
+import com.baomidou.mybatisplus.core.mapper.BaseMapper;
4
+import com.yunzhi.marketing.xlk.entity.CustomerPreparatory;
5
+import org.apache.ibatis.annotations.Mapper;
6
+
7
+/**
8
+ * <p>
9
+ * 客户认筹单  Mapper 接口
10
+ * </p>
11
+ *
12
+ * @author jobob
13
+ * @since 2021-07-30
14
+ */
15
+@Mapper
16
+public interface CustomerPreparatoryMapper extends BaseMapper<CustomerPreparatory> {
17
+
18
+}

+ 18
- 0
src/main/java/com/yunzhi/marketing/xlk/mapper/CustomerSignatoryMapper.java 查看文件

@@ -0,0 +1,18 @@
1
+package com.yunzhi.marketing.xlk.mapper;
2
+
3
+import com.baomidou.mybatisplus.core.mapper.BaseMapper;
4
+import com.yunzhi.marketing.xlk.entity.CustomerSignatory;
5
+import org.apache.ibatis.annotations.Mapper;
6
+
7
+/**
8
+ * <p>
9
+ * 客户签约单  Mapper 接口
10
+ * </p>
11
+ *
12
+ * @author jobob
13
+ * @since 2021-07-30
14
+ */
15
+@Mapper
16
+public interface CustomerSignatoryMapper extends BaseMapper<CustomerSignatory> {
17
+
18
+}

+ 18
- 0
src/main/java/com/yunzhi/marketing/xlk/mapper/CustomerSubscribeMapper.java 查看文件

@@ -0,0 +1,18 @@
1
+package com.yunzhi.marketing.xlk.mapper;
2
+
3
+import com.baomidou.mybatisplus.core.mapper.BaseMapper;
4
+import com.yunzhi.marketing.xlk.entity.CustomerSubscribe;
5
+import org.apache.ibatis.annotations.Mapper;
6
+
7
+/**
8
+ * <p>
9
+ * 客户认购单  Mapper 接口
10
+ * </p>
11
+ *
12
+ * @author jobob
13
+ * @since 2021-07-30
14
+ */
15
+@Mapper
16
+public interface CustomerSubscribeMapper extends BaseMapper<CustomerSubscribe> {
17
+
18
+}

+ 18
- 0
src/main/java/com/yunzhi/marketing/xlk/mapper/CustomerVisitMapper.java 查看文件

@@ -0,0 +1,18 @@
1
+package com.yunzhi.marketing.xlk.mapper;
2
+
3
+import com.baomidou.mybatisplus.core.mapper.BaseMapper;
4
+import com.yunzhi.marketing.xlk.entity.CustomerVisit;
5
+import org.apache.ibatis.annotations.Mapper;
6
+
7
+/**
8
+ * <p>
9
+ * 客户到访单  Mapper 接口
10
+ * </p>
11
+ *
12
+ * @author jobob
13
+ * @since 2021-07-30
14
+ */
15
+@Mapper
16
+public interface CustomerVisitMapper extends BaseMapper<CustomerVisit> {
17
+
18
+}

+ 8
- 0
src/main/java/com/yunzhi/marketing/xlk/service/IBuildingChannelService.java 查看文件

@@ -1,6 +1,8 @@
1 1
 package com.yunzhi.marketing.xlk.service;
2 2
 
3 3
 import com.baomidou.mybatisplus.extension.service.IService;
4
+import com.yunzhi.marketing.base.ResponseBean;
5
+import com.yunzhi.marketing.entity.TaPerson;
4 6
 import com.yunzhi.marketing.xlk.entity.BuildingChannel;
5 7
 
6 8
 /**
@@ -13,4 +15,10 @@ import com.yunzhi.marketing.xlk.entity.BuildingChannel;
13 15
  */
14 16
 public interface IBuildingChannelService extends IService<BuildingChannel> {
15 17
 
18
+    /**
19
+     * 获取当前渠道的楼盘列表
20
+     * @param person
21
+     * @return
22
+     */
23
+    ResponseBean getChannelBuildingList(TaPerson person);
16 24
 }

+ 16
- 0
src/main/java/com/yunzhi/marketing/xlk/service/ICustomerPreparatoryService.java 查看文件

@@ -0,0 +1,16 @@
1
+package com.yunzhi.marketing.xlk.service;
2
+
3
+import com.baomidou.mybatisplus.extension.service.IService;
4
+import com.yunzhi.marketing.xlk.entity.CustomerPreparatory;
5
+
6
+/**
7
+ * <p>
8
+ * 客户认筹单  服务类
9
+ * </p>
10
+ *
11
+ * @author jobob
12
+ * @since 2021-07-30
13
+ */
14
+public interface ICustomerPreparatoryService extends IService<CustomerPreparatory> {
15
+
16
+}

+ 16
- 0
src/main/java/com/yunzhi/marketing/xlk/service/ICustomerSignatoryService.java 查看文件

@@ -0,0 +1,16 @@
1
+package com.yunzhi.marketing.xlk.service;
2
+
3
+import com.baomidou.mybatisplus.extension.service.IService;
4
+import com.yunzhi.marketing.xlk.entity.CustomerSignatory;
5
+
6
+/**
7
+ * <p>
8
+ * 客户签约单  服务类
9
+ * </p>
10
+ *
11
+ * @author jobob
12
+ * @since 2021-07-30
13
+ */
14
+public interface ICustomerSignatoryService extends IService<CustomerSignatory> {
15
+
16
+}

+ 16
- 0
src/main/java/com/yunzhi/marketing/xlk/service/ICustomerSubscribeService.java 查看文件

@@ -0,0 +1,16 @@
1
+package com.yunzhi.marketing.xlk.service;
2
+
3
+import com.baomidou.mybatisplus.extension.service.IService;
4
+import com.yunzhi.marketing.xlk.entity.CustomerSubscribe;
5
+
6
+/**
7
+ * <p>
8
+ * 客户认购单  服务类
9
+ * </p>
10
+ *
11
+ * @author jobob
12
+ * @since 2021-07-30
13
+ */
14
+public interface ICustomerSubscribeService extends IService<CustomerSubscribe> {
15
+
16
+}

+ 16
- 0
src/main/java/com/yunzhi/marketing/xlk/service/ICustomerVisitService.java 查看文件

@@ -0,0 +1,16 @@
1
+package com.yunzhi.marketing.xlk.service;
2
+
3
+import com.baomidou.mybatisplus.extension.service.IService;
4
+import com.yunzhi.marketing.xlk.entity.CustomerVisit;
5
+
6
+/**
7
+ * <p>
8
+ * 客户到访单  服务类
9
+ * </p>
10
+ *
11
+ * @author jobob
12
+ * @since 2021-07-30
13
+ */
14
+public interface ICustomerVisitService extends IService<CustomerVisit> {
15
+
16
+}

+ 17
- 0
src/main/java/com/yunzhi/marketing/xlk/service/impl/BuildingChannelServiceImpl.java 查看文件

@@ -1,11 +1,16 @@
1 1
 package com.yunzhi.marketing.xlk.service.impl;
2 2
 
3 3
 import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
4
+import com.yunzhi.marketing.base.ResponseBean;
5
+import com.yunzhi.marketing.entity.TaBuilding;
6
+import com.yunzhi.marketing.entity.TaPerson;
4 7
 import com.yunzhi.marketing.xlk.entity.BuildingChannel;
5 8
 import com.yunzhi.marketing.xlk.mapper.BuildingChannelMapper;
6 9
 import com.yunzhi.marketing.xlk.service.IBuildingChannelService;
7 10
 import org.springframework.stereotype.Service;
8 11
 
12
+import java.util.List;
13
+
9 14
 /**
10 15
  * <p>
11 16
  * 楼盘渠道表  服务实现类
@@ -17,4 +22,16 @@ import org.springframework.stereotype.Service;
17 22
 @Service
18 23
 public class BuildingChannelServiceImpl extends ServiceImpl<BuildingChannelMapper, BuildingChannel> implements IBuildingChannelService {
19 24
 
25
+    /**
26
+     * 获取当前渠道的楼盘列表
27
+     *
28
+     * @param person
29
+     * @return
30
+     */
31
+    @Override
32
+    public ResponseBean getChannelBuildingList(TaPerson person) {
33
+        // 获取当前登录人的渠道信息
34
+        List<TaBuilding> list = this.baseMapper.getChannelBuildingList(person.getPersonId());
35
+        return ResponseBean.success(list);
36
+    }
20 37
 }

+ 20
- 0
src/main/java/com/yunzhi/marketing/xlk/service/impl/CustomerPreparatoryServiceImpl.java 查看文件

@@ -0,0 +1,20 @@
1
+package com.yunzhi.marketing.xlk.service.impl;
2
+
3
+import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
4
+import com.yunzhi.marketing.xlk.entity.CustomerPreparatory;
5
+import com.yunzhi.marketing.xlk.mapper.CustomerPreparatoryMapper;
6
+import com.yunzhi.marketing.xlk.service.ICustomerPreparatoryService;
7
+import org.springframework.stereotype.Service;
8
+
9
+/**
10
+ * <p>
11
+ * 客户认筹单  服务实现类
12
+ * </p>
13
+ *
14
+ * @author jobob
15
+ * @since 2021-07-30
16
+ */
17
+@Service
18
+public class CustomerPreparatoryServiceImpl extends ServiceImpl<CustomerPreparatoryMapper, CustomerPreparatory> implements ICustomerPreparatoryService {
19
+
20
+}

+ 20
- 0
src/main/java/com/yunzhi/marketing/xlk/service/impl/CustomerSignatoryServiceImpl.java 查看文件

@@ -0,0 +1,20 @@
1
+package com.yunzhi.marketing.xlk.service.impl;
2
+
3
+import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
4
+import com.yunzhi.marketing.xlk.entity.CustomerSignatory;
5
+import com.yunzhi.marketing.xlk.mapper.CustomerSignatoryMapper;
6
+import com.yunzhi.marketing.xlk.service.ICustomerSignatoryService;
7
+import org.springframework.stereotype.Service;
8
+
9
+/**
10
+ * <p>
11
+ * 客户签约单  服务实现类
12
+ * </p>
13
+ *
14
+ * @author jobob
15
+ * @since 2021-07-30
16
+ */
17
+@Service
18
+public class CustomerSignatoryServiceImpl extends ServiceImpl<CustomerSignatoryMapper, CustomerSignatory> implements ICustomerSignatoryService {
19
+
20
+}

+ 20
- 0
src/main/java/com/yunzhi/marketing/xlk/service/impl/CustomerSubscribeServiceImpl.java 查看文件

@@ -0,0 +1,20 @@
1
+package com.yunzhi.marketing.xlk.service.impl;
2
+
3
+import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
4
+import com.yunzhi.marketing.xlk.entity.CustomerSubscribe;
5
+import com.yunzhi.marketing.xlk.mapper.CustomerSubscribeMapper;
6
+import com.yunzhi.marketing.xlk.service.ICustomerSubscribeService;
7
+import org.springframework.stereotype.Service;
8
+
9
+/**
10
+ * <p>
11
+ * 客户认购单  服务实现类
12
+ * </p>
13
+ *
14
+ * @author jobob
15
+ * @since 2021-07-30
16
+ */
17
+@Service
18
+public class CustomerSubscribeServiceImpl extends ServiceImpl<CustomerSubscribeMapper, CustomerSubscribe> implements ICustomerSubscribeService {
19
+
20
+}

+ 20
- 0
src/main/java/com/yunzhi/marketing/xlk/service/impl/CustomerVisitServiceImpl.java 查看文件

@@ -0,0 +1,20 @@
1
+package com.yunzhi.marketing.xlk.service.impl;
2
+
3
+import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
4
+import com.yunzhi.marketing.xlk.entity.CustomerVisit;
5
+import com.yunzhi.marketing.xlk.mapper.CustomerVisitMapper;
6
+import com.yunzhi.marketing.xlk.service.ICustomerVisitService;
7
+import org.springframework.stereotype.Service;
8
+
9
+/**
10
+ * <p>
11
+ * 客户到访单  服务实现类
12
+ * </p>
13
+ *
14
+ * @author jobob
15
+ * @since 2021-07-30
16
+ */
17
+@Service
18
+public class CustomerVisitServiceImpl extends ServiceImpl<CustomerVisitMapper, CustomerVisit> implements ICustomerVisitService {
19
+
20
+}

+ 10
- 0
src/main/resources/mapper/xlk/BuildingChannelMapper.xml 查看文件

@@ -2,4 +2,14 @@
2 2
 <!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
3 3
 <mapper namespace="com.yunzhi.marketing.xlk.mapper.BuildingChannelMapper">
4 4
 
5
+    <select id="getChannelBuildingList" resultType="com.yunzhi.marketing.entity.TaBuilding">
6
+        SELECT
7
+            b.*
8
+        FROM
9
+            xlk_building_channel t
10
+            INNER JOIN ta_channel_person c ON t.channel_id = c.channel_id
11
+            LEFT JOIN ta_building b ON t.building_id = b.building_id
12
+        WHERE
13
+            c.person_id = #{personId}
14
+    </select>
5 15
 </mapper>

+ 5
- 0
src/main/resources/mapper/xlk/CustomerPreparatoryMapper.xml 查看文件

@@ -0,0 +1,5 @@
1
+<?xml version="1.0" encoding="UTF-8"?>
2
+<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
3
+<mapper namespace="com.yunzhi.marketing.xlk.mapper.CustomerPreparatoryMapper">
4
+
5
+</mapper>

+ 5
- 0
src/main/resources/mapper/xlk/CustomerSignatoryMapper.xml 查看文件

@@ -0,0 +1,5 @@
1
+<?xml version="1.0" encoding="UTF-8"?>
2
+<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
3
+<mapper namespace="com.yunzhi.marketing.xlk.mapper.CustomerSignatoryMapper">
4
+
5
+</mapper>

+ 5
- 0
src/main/resources/mapper/xlk/CustomerSubscribeMapper.xml 查看文件

@@ -0,0 +1,5 @@
1
+<?xml version="1.0" encoding="UTF-8"?>
2
+<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
3
+<mapper namespace="com.yunzhi.marketing.xlk.mapper.CustomerSubscribeMapper">
4
+
5
+</mapper>

+ 5
- 0
src/main/resources/mapper/xlk/CustomerVisitMapper.xml 查看文件

@@ -0,0 +1,5 @@
1
+<?xml version="1.0" encoding="UTF-8"?>
2
+<!DOCTYPE mapper PUBLIC "-//mybatis.org//DTD Mapper 3.0//EN" "http://mybatis.org/dtd/mybatis-3-mapper.dtd">
3
+<mapper namespace="com.yunzhi.marketing.xlk.mapper.CustomerVisitMapper">
4
+
5
+</mapper>