傅行帆 5 years ago
parent
commit
30789e4fdc

+ 7
- 3
src/main/java/com/huiju/estateagents/activity/controller/ActivityController.java View File

@@ -1,6 +1,7 @@
1 1
 package com.huiju.estateagents.activity.controller;
2 2
 
3 3
 import com.baomidou.mybatisplus.core.conditions.query.QueryWrapper;
4
+import com.baomidou.mybatisplus.extension.plugins.pagination.Page;
4 5
 import com.huiju.estateagents.activity.service.ActivityServiceI;
5 6
 import com.huiju.estateagents.base.BaseController;
6 7
 import com.huiju.estateagents.base.ResponseBean;
@@ -66,17 +67,20 @@ public class ActivityController extends BaseController {
66 67
 		queryWrapper.eq("customer_id",customerId);
67 68
 		TaRecommendCustomer taRecommendCustomer = taRecommendCustomerService.getOne(queryWrapper);
68 69
 		if (null == taRecommendCustomer){
69
-			return ResponseBean.error("验证人员信息失败",ResponseBean.ERROR_UNAVAILABLE);
70
+			//验证人员信息失败小程序端希望是空数组对象
71
+			return ResponseBean.success(new Page(pageNumber,pageSize));
70 72
 		}
71 73
 		if (null == taRecommendCustomer.getPersonId()){
72
-			return ResponseBean.error("验证人员信息失败",ResponseBean.ERROR_UNAVAILABLE);
74
+			//验证人员信息失败小程序端希望是空数组对象
75
+			return ResponseBean.success(new Page(pageNumber,pageSize));
73 76
 		}
74 77
 		
75 78
 		QueryWrapper<TaPerson> taPersonQueryWrapper = new QueryWrapper<>();
76 79
 		taPersonQueryWrapper.eq("person_id",taRecommendCustomer.getPersonId());
77 80
 		TaPerson person = taPersonService.getOne(taPersonQueryWrapper);
78 81
 		if (null == person){
79
-			return ResponseBean.error("验证人员信息失败",ResponseBean.ERROR_UNAVAILABLE);
82
+			//验证人员信息失败小程序端希望是空数组对象
83
+			return ResponseBean.success(new Page(pageNumber,pageSize));
80 84
 		}
81 85
 		responseBean = activityService.getCustomerActivityList(pageNumber,pageSize,orgId,person);
82 86
 		return responseBean;

+ 1
- 1
src/main/java/com/huiju/estateagents/statistic/service/impl/TsCustomerStatisticDailyServiceImpl.java View File

@@ -104,7 +104,7 @@ public class TsCustomerStatisticDailyServiceImpl extends ServiceImpl<TsCustomerS
104 104
 			//合并数据
105 105
 			list.forEach(l -> {
106 106
 				if (newDate.equals(l.getDay())){
107
-					tsCustomerStatisticDaily.setCustomerNum(l.getCustomerNum());
107
+					tsCustomerStatisticDaily.setCustomerNum(tsCustomerStatisticDaily.getCustomerNum() + l.getCustomerNum());
108 108
 				}
109 109
 			});
110 110
 			newList.add(tsCustomerStatisticDaily);

+ 1
- 1
src/main/java/com/huiju/estateagents/statistic/service/impl/TsCustomerStatisticMonthlyServiceImpl.java View File

@@ -101,7 +101,7 @@ public class TsCustomerStatisticMonthlyServiceImpl extends ServiceImpl<TsCustome
101 101
 			tsCustomerStatisticMonthly.setRealtyConsultant(personId);
102 102
 			list.forEach(l -> {
103 103
 				if (newDate.equals(l.getMonth())){
104
-					tsCustomerStatisticMonthly.setCustomerNum(l.getCustomerNum());
104
+					tsCustomerStatisticMonthly.setCustomerNum(tsCustomerStatisticMonthly.getCustomerNum() + l.getCustomerNum());
105 105
 				}
106 106
 			});
107 107
 			newList.add(tsCustomerStatisticMonthly);