|
@@ -7,8 +7,10 @@ import com.baomidou.mybatisplus.extension.service.impl.ServiceImpl;
|
7
|
7
|
import com.yunzhi.marketing.base.ResponseBean;
|
8
|
8
|
import com.yunzhi.marketing.common.CommConstant;
|
9
|
9
|
import com.yunzhi.marketing.common.StringUtils;
|
|
10
|
+import com.yunzhi.marketing.entity.TaBuilding;
|
10
|
11
|
import com.yunzhi.marketing.entity.TaPerson;
|
11
|
12
|
import com.yunzhi.marketing.entity.TaRecommendCustomer;
|
|
13
|
+import com.yunzhi.marketing.mapper.TaBuildingMapper;
|
12
|
14
|
import com.yunzhi.marketing.mapper.TaPersonMapper;
|
13
|
15
|
import com.yunzhi.marketing.mapper.TaRecommendCustomerMapper;
|
14
|
16
|
import com.yunzhi.marketing.po.MineRecommendCustomerPO;
|
|
@@ -50,6 +52,9 @@ public class ChannelCustomerServiceImpl extends ServiceImpl<ChannelCustomerMappe
|
50
|
52
|
|
51
|
53
|
@Autowired
|
52
|
54
|
private TaPersonMapper taPersonMapper;
|
|
55
|
+
|
|
56
|
+ @Autowired
|
|
57
|
+ private TaBuildingMapper taBuildingMapper;
|
53
|
58
|
/**
|
54
|
59
|
* 审核
|
55
|
60
|
*
|
|
@@ -88,14 +93,16 @@ public class ChannelCustomerServiceImpl extends ServiceImpl<ChannelCustomerMappe
|
88
|
93
|
queryWrapper.eq(TaRecommendCustomer::getBuildingId,customer.getBuildingId());
|
89
|
94
|
TaRecommendCustomer recommendCustomer = taRecommendCustomerMapper.selectOne(queryWrapper);
|
90
|
95
|
if (null == recommendCustomer) {
|
|
96
|
+ TaBuilding building = taBuildingMapper.selectById(customer.getBuildingId());
|
91
|
97
|
// 进业务客户表
|
92
|
98
|
TaRecommendCustomer taRecommendCustomer = new TaRecommendCustomer();
|
93
|
|
- taRecommendCustomer.setName(customerVisit.getName());
|
|
99
|
+ taRecommendCustomer.setName(customer.getName());
|
94
|
100
|
taRecommendCustomer.setPicture(customer.getPicture());
|
95
|
101
|
taRecommendCustomer.setPhone(customer.getPhone());
|
96
|
102
|
taRecommendCustomer.setSex(customer.getSex());
|
97
|
103
|
taRecommendCustomer.setRecommendPerson(customer.getRecommendPerson());
|
98
|
104
|
taRecommendCustomer.setBuildingId(customer.getBuildingId());
|
|
105
|
+ taRecommendCustomer.setIntention(building.getBuildingName());
|
99
|
106
|
taRecommendCustomer.setReportRecommendStatus(CommConstant.RECOMMENDED);
|
100
|
107
|
taRecommendCustomer.setVerifyStatus(CommConstant.VERIFY_AGREE);
|
101
|
108
|
taRecommendCustomer.setCreateDate(LocalDateTime.now());
|
|
@@ -175,6 +182,7 @@ public class ChannelCustomerServiceImpl extends ServiceImpl<ChannelCustomerMappe
|
175
|
182
|
queryWrapper.eq(TaRecommendCustomer::getBuildingId,customer.getBuildingId());
|
176
|
183
|
TaRecommendCustomer recommendCustomer = taRecommendCustomerMapper.selectOne(queryWrapper);
|
177
|
184
|
if (null == recommendCustomer) {
|
|
185
|
+ TaBuilding building = taBuildingMapper.selectById(customer.getBuildingId());
|
178
|
186
|
// 进业务客户表
|
179
|
187
|
TaRecommendCustomer taRecommendCustomer = new TaRecommendCustomer();
|
180
|
188
|
taRecommendCustomer.setName(customerVisit.getName());
|
|
@@ -183,6 +191,7 @@ public class ChannelCustomerServiceImpl extends ServiceImpl<ChannelCustomerMappe
|
183
|
191
|
taRecommendCustomer.setSex(customer.getSex());
|
184
|
192
|
taRecommendCustomer.setRecommendPerson(customer.getRecommendPerson());
|
185
|
193
|
taRecommendCustomer.setBuildingId(customer.getBuildingId());
|
|
194
|
+ taRecommendCustomer.setIntention(building.getBuildingName());
|
186
|
195
|
taRecommendCustomer.setReportRecommendStatus(CommConstant.RECOMMENDED);
|
187
|
196
|
taRecommendCustomer.setVerifyStatus(CommConstant.VERIFY_AGREE);
|
188
|
197
|
taRecommendCustomer.setCreateDate(LocalDateTime.now());
|