diff --git a/pages/center/consumer/index.vue b/pages/center/consumer/index.vue
index 2a87c77..1547ca0 100644
--- a/pages/center/consumer/index.vue
+++ b/pages/center/consumer/index.vue
@@ -578,6 +578,9 @@
onLoad(options) {
this.LOADING = true;
this.isnorefresh = options.refresh;
+ if (options.dataType) this.activeTotal = options.dataType
+ if (options.staTime) this.screen.staTime = options.staTime
+ if (options.endTime) this.screen.endTime = options.endTime
},
onShow() {
// dataCode: 身份标识 2:项目总、3:客服、4:策划、5:经理、6:置业顾问
@@ -1266,6 +1269,7 @@
.content-last {
display: flex;
+
.content-last-tab {
width: 33.4%;
height: 78rpx;
diff --git a/pages/index/customer.vue b/pages/index/customer.vue
index 429d888..c446c9a 100644
--- a/pages/index/customer.vue
+++ b/pages/index/customer.vue
@@ -131,8 +131,35 @@
this.init()
this.updateInit()
this.queryHaveDept()
+ this.initrealTimeStatistics()
},
methods: {
+
+ //实时统计
+ initrealTimeStatistics() {
+ uni.request({
+ url: config.service.realTimeStatistics,
+ method: "POST",
+ header: {
+ 'content-type': 'application/json',
+ 'Access-Token': uni.getStorageSync('weapp_session_login_data').token
+ },
+ data: {
+ houseId: this.buildingID
+ },
+ success: (data) => {
+ if (data.data.data == null) {
+ return
+ } else {
+ this.tabbarList[1].count = data.data.data.receivingCustomer || 0
+ this.$forceUpdate()
+ }
+ },
+ fail: () => {
+ }
+ })
+ },
+
// 删除接待
deleteReception(data) {
uni.showModal({
@@ -176,6 +203,7 @@
},
reshCustom() {
this.init()
+ this.initrealTimeStatistics()
},
tapThevisiting(item) {
uni.showLoading({
@@ -277,6 +305,7 @@
title: "操作成功"
})
this.init();
+ this.initrealTimeStatistics()
}).catch(() => {
uni.hideLoading()
});
diff --git a/pages/index/index.vue b/pages/index/index.vue
index 4596c64..b05c20a 100644
--- a/pages/index/index.vue
+++ b/pages/index/index.vue
@@ -86,14 +86,16 @@
已用小时
- {{paraphraseObj.surplusSum || 0}}
+
+ {{paraphraseObj.surplusSum || 0}}
+
剩余小时
- 设备
+ 设备
{{equipmentobj.totalNum || 0}}
@@ -128,7 +130,7 @@
{{realtimeobj.tagCustomer || 0}}
未标顾问
-
+
{{realtimeobj.prohibitedCustomer || 0}}
@@ -149,8 +151,8 @@
{{max100(realtimeobj.wordFinishFraction)}}%
平均挖掘率
-
-
+
+
{{realtimeobj.sumLevelFraction || 0}}%
客户意向度
@@ -197,14 +199,14 @@
{{max100(Thisweekobj.wordFinishFraction)}}%
平均挖掘率
-
+
{{max100(Thisweekobj.fraction)}}%
平均执行率
-
-
-
+
+
+
{{Thisweekobj.sumLevelFraction || 0}}%
客户意向度
@@ -443,12 +445,32 @@
this.initworkThisWeek()
this.initrealTimeStatistics()
this.findByHouseIdForRecharge()
-
+
setTimeout(() => {
uni.stopPullDownRefresh()
}, 3000)
},
methods: {
+ // 跳转客户详情
+ toCustomerManagement(str) {
+ if (str != 'dateType=0') {
+ // dateType == 2 //
+ if (this.zhixingcenterindex != 7) {
+ uni.navigateTo({
+ url: `/pages/center/consumer/index?refresh=refresh&dataType=${this.zhixingcenterindex}`
+ })
+ } else {
+ uni.navigateTo({
+ url: `/pages/center/consumer/index?refresh=refresh&dataType=4&staTime=${this.statDateStart}&endTime=${this.statDateEnd}`
+ })
+ }
+ } else {
+ uni.navigateTo({
+ url: `/pages/center/consumer/index?refresh=refresh&${str}`
+ })
+ }
+ },
+
max100(num) {
if (num > 100) {
return 100
@@ -604,6 +626,7 @@
return
} else {
this.Thisweekobj = {
+ ...data.data.data,
sumCustomer: data.data.data.sumCustomer,
receivingCustomer: data.data.data.receivingCustomer,
activeCustomer: data.data.data.activeCustomer,
@@ -636,6 +659,7 @@
return
} else {
this.realtimeobj = {
+ ...data.data.data,
sumCustomer: data.data.data.sumCustomer || 0,
receivingCustomer: data.data.data.receivingCustomer || 0,
activeCustomer: data.data.data.activeCustomer || 0,
@@ -644,8 +668,9 @@
tagCustomer: data.data.data.tagCustomer || 0,
fraction: data.data.data.fraction || 0,
wordFinishFraction: data.data.data.wordFinishFraction || 0,
- receptionCount: data.data.data.receptionCount || 0
+ receptionCount: data.data.data.receptionCount || 0,
}
+ this.tabbarList[1].count = data.data.data.receivingCustomer || 0
}
},
fail: () => {
@@ -653,7 +678,7 @@
}
})
},
-
+
// 转写充值剩余
findByHouseIdForRecharge() {
this.$u.get(`/cusLvStatistics/findByHouseIdForRecharge?houseId=${this.buildingID}`).then(res => {