From 2f2088afe095a098e395740413d8f416ca2f01b1 Mon Sep 17 00:00:00 2001
From: douzhuo <17611323298@163.com>
Date: Wed, 23 Nov 2022 10:09:34 +0800
Subject: [PATCH] =?UTF-8?q?=E6=96=B0=E5=A2=9E=E5=88=86=E4=BA=AB=E3=80=81?=
=?UTF-8?q?=E6=97=A5=E5=91=A8=E6=8A=A5=E6=8E=A5=E5=8F=A3=E9=A1=B9=E7=9B=AE?=
=?UTF-8?q?id=E5=AD=97=E6=AE=B5?=
MIME-Version: 1.0
Content-Type: text/plain; charset=UTF-8
Content-Transfer-Encoding: 8bit
---
App.vue | 8 ++--
pages/index/personal.vue | 2 +-
pages/reportExcel/dayReport.vue | 73 +++++++++++++++++++++++----------
3 files changed, 58 insertions(+), 25 deletions(-)
diff --git a/App.vue b/App.vue
index 0c977f9..e9e2cba 100644
--- a/App.vue
+++ b/App.vue
@@ -156,9 +156,11 @@
});
},
onShow(options) {
- this.$u.post('/user/addLoginCount', {
- houseId: uni.getStorageSync('buildingID').id
- })
+ if (uni.getStorageSync('buildingID').id) {
+ this.$u.post('/user/addLoginCount', {
+ houseId: uni.getStorageSync('buildingID').id
+ }).then(res=>{}).catc(e=>{})
+ }
const token = uni.getStorageSync("weapp_session_login_data")
if (typeof token.token != "string") {
console.log("没有")
diff --git a/pages/index/personal.vue b/pages/index/personal.vue
index bc7daed..7bbde64 100644
--- a/pages/index/personal.vue
+++ b/pages/index/personal.vue
@@ -167,7 +167,7 @@
content: '确定要退出?',
cancelColor: "#999999",
showCancel: true,
- success(res) {
+ success:(res) => {
if (res.confirm) {
app.Closewebsocke()
uni.clearStorageSync(); //清除缓存
diff --git a/pages/reportExcel/dayReport.vue b/pages/reportExcel/dayReport.vue
index 66f7fff..d9dda43 100644
--- a/pages/reportExcel/dayReport.vue
+++ b/pages/reportExcel/dayReport.vue
@@ -188,7 +188,7 @@
{{ rank.title || '--' }}
- ({{ rank.value/60 || 0 }}m)
+ ({{ tofixed2(rank.value/60) || 0 }}m)
@@ -279,24 +279,46 @@
平均执行率最低的顾问:
执行率最低的项目:
-
-
-
-
- {{ rank.title || '--' }}
+
+
+
+
+
+ {{ rank.title || '--' }}
+
+
+ {{ rank.value || 0 }}%
+
-
- {{ rank.value || 0 }}%
+
+
+
+
+ 暂无数据
-
-
+
+
+
+
+
+
+
+
+ {{ rankIndex || '--' }}
+
+
+ {{ rank || 0 }}%
+
+
+
-
-
- 暂无数据
-
-
-
+
+
+ 暂无数据
+
+
+
+
@@ -472,6 +494,15 @@
},
methods: {
+
+ tofixed2(time) {
+ if (time) {
+ return time.toFixed(2)
+ } else {
+ return 0
+ }
+ },
+
// 项目拷贝
copys() {
@@ -492,7 +523,7 @@
3、平均接待时长:${ this.weekObj.avgDuration || 0 }min
对比昨天:${this.weekObj.avgDurationPK > 0 ? '+' : '' }${ this.weekObj.avgDurationPK || 0 }min`
-
+
if (this.consultant.length > 0) {
str += `
@@ -509,7 +540,7 @@
5、项目平均接访时长排名:`
this.recording.map((item, index) => {
str += `
- top${index+1}.${item.title || '--'}${item.value/60||'0'}m`
+ top${index+1}.${item.title || '--'}${this.tofixed2(item.value/60)||'0'}m`
})
}
@@ -517,10 +548,10 @@
str += `
6、执行率最低的项目:`
- this.lowest.map((item, index) => {
+ for (let i in this.weekObj.minFraction) {
str += `
- ${item.title || '--'}${item.value||'0'}%`
- })
+ ${i || '--'}${this.weekObj.minFraction[i]||'0'}%`
+ }
}