消息回复率

This commit is contained in:
shijingjing
2022-12-22 17:18:34 +08:00
parent c68d9ba2c4
commit f2e141dc02

View File

@@ -68,6 +68,7 @@ export default {
name: 'message', name: 'message',
data() { data() {
return { return {
replyData: {},
privateCard: {}, privateCard: {},
privateData: [], privateData: [],
privateDate: [], privateDate: [],
@@ -95,7 +96,7 @@ export default {
// 回复率 // 回复率
this.$http.post(`/app/wxgroupstatistic/replyPercentage`).then(res=> { this.$http.post(`/app/wxgroupstatistic/replyPercentage`).then(res=> {
if(res?.data) { if(res?.data) {
console.log(res); this.replyData = res.data
} }
}) })
this.getPrivateData() this.getPrivateData()
@@ -143,7 +144,7 @@ export default {
}, },
title: { title: {
zlevel: 0, zlevel: 0,
text: ['{name|昨日}\n{value|12}'], text: [`{name|昨日}\n{value|${ this.replyData?.replyPercentage || 0 } %}`],
top: 'center', top: 'center',
left: '46%', left: '46%',
textAlign: 'center', textAlign: 'center',
@@ -162,7 +163,7 @@ export default {
}, },
}, },
}, },
color: ['#3975C6','#F0F2F5'], color: ['#3975C6','#5d5c5c'],
series: [ series: [
{ {
name: '昨天', name: '昨天',
@@ -174,8 +175,8 @@ export default {
show: false, show: false,
}, },
data: [ data: [
{ value: 580, name: '' }, { value: this.replyData?.replyPercentage, name: '已回复聊天比' },
{ value: 484, name: '' }, { value: 100 - this.replyData?.replyPercentage, name: '未回复聊天比' },
] ]
} }
] ]
@@ -191,7 +192,7 @@ export default {
}, },
title: { title: {
zlevel: 0, zlevel: 0,
text: ['{name|近7天}\n{value|12}'], text: [`{name|近7天}\n{value|${ this.replyData?.weekSum || 0 } %}`],
top: 'center', top: 'center',
left: '46%', left: '46%',
textAlign: 'center', textAlign: 'center',
@@ -222,8 +223,8 @@ export default {
show: false, show: false,
}, },
data: [ data: [
{ value: 580, name: '' }, { value: this.replyData?.weekSum, name: '近7天回复率' },
{ value: 484, name: '女' }, { value: 100 - this.replyData?.weekSum, name: '女' },
] ]
} }
] ]
@@ -239,7 +240,7 @@ export default {
}, },
title: { title: {
zlevel: 0, zlevel: 0,
text: ['{name|近30天}\n{value|12}'], text: [`{name|近30天}\n{value|${ this.replyData?.monthSum || 0 } %}`],
top: 'center', top: 'center',
left: '46%', left: '46%',
textAlign: 'center', textAlign: 'center',
@@ -270,8 +271,8 @@ export default {
show: false, show: false,
}, },
data: [ data: [
{ value: 580, name: '' }, { value: this.replyData?.monthSum, name: '近一个月回复率' },
{ value: 484, name: '' }, { value: 100 - this.replyData?.monthSum, name: '近一个月未回复率' },
] ]
} }
] ]
@@ -408,6 +409,8 @@ export default {
font-size: 32px; font-size: 32px;
color: #333333; color: #333333;
font-weight: 600; font-weight: 600;
color: #5d5c5c;
} }
} }