Bläddra i källkod

Merge branch 'develop' of http://git.ycjcjy.com/marketing/services into develop

Your Name 3 år sedan
förälder
incheckning
107cb3d685

+ 7
- 1
src/main/java/com/yunzhi/marketing/po/TaRecommendCustomerVO.java Visa fil

@@ -9,6 +9,7 @@ import com.baomidou.mybatisplus.core.metadata.IPage;
9 9
 import com.yunzhi.marketing.center.taUser.entity.TaUser;
10 10
 import com.yunzhi.marketing.entity.PersonIntention;
11 11
 import com.yunzhi.marketing.entity.TaPersonVisitRecord;
12
+import com.yunzhi.marketing.xlk.entity.ChannelCustomer;
12 13
 import com.yunzhi.marketing.xlk.entity.CustomerPreparatory;
13 14
 import com.yunzhi.marketing.xlk.entity.CustomerSignatory;
14 15
 import com.yunzhi.marketing.xlk.entity.CustomerVisit;
@@ -199,7 +200,7 @@ public class TaRecommendCustomerVO implements Serializable {
199 200
 
200 201
     @TableField(exist = false)
201 202
     private List<PersonIntention> intentions;
202
-    
203
+
203 204
     @TableField(exist = false)
204 205
     private String intentionName;
205 206
 
@@ -251,4 +252,9 @@ public class TaRecommendCustomerVO implements Serializable {
251 252
      * 认筹
252 253
      */
253 254
     private CustomerPreparatory customerPreparatory;
255
+
256
+    /**
257
+     * 渠道客户
258
+     */
259
+    private ChannelCustomer channelCustomer;
254 260
 }

+ 6
- 0
src/main/java/com/yunzhi/marketing/service/impl/TaRecommendCustomerServiceImpl.java Visa fil

@@ -716,6 +716,12 @@ public class TaRecommendCustomerServiceImpl extends ServiceImpl<TaRecommendCusto
716 716
             taRecommendCustomerVO.setCustomerSignatory(customerSignatory);
717 717
         }
718 718
 
719
+        LambdaQueryWrapper<ChannelCustomer> channelCustomerLambdaQueryWrapper = new LambdaQueryWrapper<>();
720
+        channelCustomerLambdaQueryWrapper.eq(ChannelCustomer::getCustomerId,id);
721
+        ChannelCustomer customer = channelCustomerMapper.selectOne(channelCustomerLambdaQueryWrapper);
722
+        if (null != customer) {
723
+            taRecommendCustomerVO.setChannelCustomer(customer);
724
+        }
719 725
         return ResponseBean.success(taRecommendCustomerVO);
720 726
     }
721 727
 

+ 8
- 1
src/main/java/com/yunzhi/marketing/xlk/service/impl/ChannelCustomerServiceImpl.java Visa fil

@@ -104,7 +104,7 @@ public class ChannelCustomerServiceImpl extends ServiceImpl<ChannelCustomerMappe
104 104
             taRecommendCustomer.setOrgId(customer.getOrgId());
105 105
             taRecommendCustomer.setPersonId(customer.getPersonId());
106 106
             taRecommendCustomer.setEntryType(CommConstant.ENTRY_VERIFY);
107
-            taRecommendCustomer.setStatus(CommConstant.CUSTOMER_REPORT);
107
+            taRecommendCustomer.setStatus(CommConstant.CUSTOMER_VISITE);
108 108
             taRecommendCustomer.setRealtyConsultant(channelCustomerDTO.getRealtyConsultant());
109 109
             taRecommendCustomer.setCirculationTime(LocalDateTime.now());
110 110
             taRecommendCustomerMapper.insert(taRecommendCustomer);
@@ -123,6 +123,13 @@ public class ChannelCustomerServiceImpl extends ServiceImpl<ChannelCustomerMappe
123 123
             customer.setVisitDate(LocalDateTime.now());
124 124
             customer.setRealtyConsultant(channelCustomerDTO.getRealtyConsultant());
125 125
             channelCustomerMapper.updateById(customer);
126
+            // 修改状态为确认到访状态
127
+            recommendCustomer.setRecommendPerson(customer.getRecommendPerson());
128
+            recommendCustomer.setVerifyStatus(CommConstant.VERIFY_AGREE);
129
+            recommendCustomer.setStatus(CommConstant.CUSTOMER_VISITE);
130
+            recommendCustomer.setRealtyConsultant(channelCustomerDTO.getRealtyConsultant());
131
+            recommendCustomer.setCirculationTime(LocalDateTime.now());
132
+            taRecommendCustomerMapper.updateById(recommendCustomer);
126 133
         }else {
127 134
             return ResponseBean.error("此客户是私客或已被报备", ResponseBean.ERROR_UNAVAILABLE);
128 135
         }