From c899dff1fce7f8054008cd9887a9729cdffd88cb Mon Sep 17 00:00:00 2001
From: WXL (wul) <wl_5969728@163.com>
Date: 星期四, 19 十一月 2026 11:34:32 +0800
Subject: [PATCH] 测试完成
---
src/views/followvisit/mzsatisfaction/index.vue | 43 ++++++++++++--
随访通用11.18 (2).zip | 0
随访通用11.18.zip | 0
src/views/sfstatistics/percentage/components/FirstFollowUp.vue | 89 +++++++++++++++++++++++++++--
随访通用11.19.zip | 0
src/views/followvisit/zysatisfaction/index.vue | 46 +++++++++++++--
6 files changed, 157 insertions(+), 21 deletions(-)
diff --git a/src/views/followvisit/mzsatisfaction/index.vue b/src/views/followvisit/mzsatisfaction/index.vue
index 9f49f34..75813ce 100644
--- a/src/views/followvisit/mzsatisfaction/index.vue
+++ b/src/views/followvisit/mzsatisfaction/index.vue
@@ -64,6 +64,7 @@
clearable
placeholder="璇烽�夋嫨鐐逛綅"
style="width: 240px"
+ @change="handlePointLocationChange"
>
<el-option
v-for="item in pointOptions"
@@ -1253,6 +1254,8 @@
checkboxlist: [],
// 鐐逛綅鍒楄〃锛堝悓寰烽櫌鍖猴紝deptType=3锛�
pointOptions: [],
+ // 鐐逛綅閫夋嫨鍘嗗彶鍊硷紙鐢ㄤ簬鈥滃叏閮�/鍏蜂綋鐐逛綅鈥濅簰鏂ュ垽鏂級
+ pointPrevLocations: [],
// 琛ㄥ崟鏍¢獙
rules: {},
};
@@ -1405,8 +1408,30 @@
});
};
walk(response && response.data);
- this.pointOptions = flat;
+ this.pointOptions = [{ label: "鍏ㄩ儴", value: "all" }, ...flat];
+ // 杩涘叆椤甸潰榛樿鏌ヨ鍏ㄩ儴鐐逛綅
+ this.topqueryParams.pointLocations = ["all"];
+ this.pointPrevLocations = ["all"];
+ if (!this.errtype) {
+ this.getList(1);
+ }
});
+ },
+ // 鐐逛綅閫夋嫨锛氬叏閮ㄤ笌鍏蜂綋鐐逛綅浜掓枼
+ handlePointLocationChange(val) {
+ const all = "all";
+ const hasAll = val.includes(all);
+ if (hasAll && val.length > 1) {
+ const prev = this.pointPrevLocations || [];
+ if (prev.includes(all)) {
+ // 涔嬪墠宸查�夆�滃叏閮ㄢ�濓紝鏈鏂板鍏蜂綋鐐逛綅 鈫� 鍘绘帀鈥滃叏閮ㄢ��
+ this.topqueryParams.pointLocations = val.filter((v) => v !== all);
+ } else {
+ // 鏈鏂板鈥滃叏閮ㄢ�� 鈫� 鍙繚鐣欌�滃叏閮ㄢ��
+ this.topqueryParams.pointLocations = [all];
+ }
+ }
+ this.pointPrevLocations = [...this.topqueryParams.pointLocations];
},
// 鐐逛綅鍚嶇О锛氬皢 pointLocation 缂栫爜鏄犲皠涓虹偣浣嶅悕绉�
@@ -1586,10 +1611,15 @@
// 鏋勯�犳煡璇�/瀵煎嚭鍙傛暟锛氶�夋嫨鐐逛綅鏃剁瀹�/鐥呭尯浼� null锛屽惁鍒欎繚鎸佸師鍊�
buildQueryParams() {
const params = { ...this.topqueryParams };
- if (
- this.topqueryParams.pointLocations &&
- this.topqueryParams.pointLocations.length > 0
- ) {
+ let locations = this.topqueryParams.pointLocations || [];
+ // 鈥滃叏閮ㄢ�濈偣浣嶏細灞曞紑涓烘墍鏈夊疄闄呯偣浣嶇紪鐮�
+ if (locations.includes("all")) {
+ locations = this.pointOptions
+ .filter((p) => p.value !== "all")
+ .map((p) => p.value);
+ }
+ params.pointLocations = locations;
+ if (locations.length > 0) {
params.leaveldeptcodes = null;
params.leavehospitaldistrictcodes = null;
}
@@ -1631,8 +1661,9 @@
scopetype: [],
leaveldeptcodes: [],
leavehospitaldistrictcodes: [],
- pointLocations: [],
+ pointLocations: ["all"],
};
+ this.pointPrevLocations = ["all"];
this.handleQuery(1);
},
handleSelectionChange(rows) {
diff --git a/src/views/followvisit/zysatisfaction/index.vue b/src/views/followvisit/zysatisfaction/index.vue
index 3edb9ba..54ea141 100644
--- a/src/views/followvisit/zysatisfaction/index.vue
+++ b/src/views/followvisit/zysatisfaction/index.vue
@@ -87,6 +87,7 @@
clearable
placeholder="璇烽�夋嫨鐐逛綅"
style="width: 240px"
+ @change="handlePointLocationChange"
>
<el-option
v-for="item in pointOptions"
@@ -1249,6 +1250,8 @@
checkboxlist: [],
// 鐐逛綅鍒楄〃锛堝悓寰烽櫌鍖猴紝deptType=3锛�
pointOptions: [],
+ // 鐐逛綅閫夋嫨鍘嗗彶鍊硷紙鐢ㄤ簬鈥滃叏閮�/鍏蜂綋鐐逛綅鈥濅簰鏂ュ垽鏂級
+ pointPrevLocations: [],
// 琛ㄥ崟鏍¢獙
rules: {},
};
@@ -1426,8 +1429,30 @@
});
};
walk(response && response.data);
- this.pointOptions = flat;
+ this.pointOptions = [{ label: "鍏ㄩ儴", value: "all" }, ...flat];
+ // 杩涘叆椤甸潰榛樿鏌ヨ鍏ㄩ儴鐐逛綅
+ this.topqueryParams.pointLocations = ["all"];
+ this.pointPrevLocations = ["all"];
+ if (!this.errtype) {
+ this.getList(1);
+ }
});
+ },
+ // 鐐逛綅閫夋嫨锛氬叏閮ㄤ笌鍏蜂綋鐐逛綅浜掓枼
+ handlePointLocationChange(val) {
+ const all = "all";
+ const hasAll = val.includes(all);
+ if (hasAll && val.length > 1) {
+ const prev = this.pointPrevLocations || [];
+ if (prev.includes(all)) {
+ // 涔嬪墠宸查�夆�滃叏閮ㄢ�濓紝鏈鏂板鍏蜂綋鐐逛綅 鈫� 鍘绘帀鈥滃叏閮ㄢ��
+ this.topqueryParams.pointLocations = val.filter((v) => v !== all);
+ } else {
+ // 鏈鏂板鈥滃叏閮ㄢ�� 鈫� 鍙繚鐣欌�滃叏閮ㄢ��
+ this.topqueryParams.pointLocations = [all];
+ }
+ }
+ this.pointPrevLocations = [...this.topqueryParams.pointLocations];
},
// 鐐逛綅鍚嶇О锛氬皢 pointLocation 缂栫爜鏄犲皠涓虹偣浣嶅悕绉�
@@ -1627,10 +1652,15 @@
// 鏋勯�犳煡璇�/瀵煎嚭鍙傛暟锛氶�夋嫨鐐逛綅鏃剁瀹�/鐥呭尯浼� null锛屽惁鍒欎繚鎸佸師鍊�
buildQueryParams() {
const params = { ...this.topqueryParams };
- if (
- this.topqueryParams.pointLocations &&
- this.topqueryParams.pointLocations.length > 0
- ) {
+ let locations = this.topqueryParams.pointLocations || [];
+ // 鈥滃叏閮ㄢ�濈偣浣嶏細灞曞紑涓烘墍鏈夊疄闄呯偣浣嶇紪鐮�
+ if (locations.includes("all")) {
+ locations = this.pointOptions
+ .filter((p) => p.value !== "all")
+ .map((p) => p.value);
+ }
+ params.pointLocations = locations;
+ if (locations.length > 0) {
params.leaveldeptcodes = null;
params.leavehospitaldistrictcodes = null;
}
@@ -1671,8 +1701,9 @@
scopetype: [],
leaveldeptcodes: [],
leavehospitaldistrictcodes: [],
- pointLocations: [],
+ pointLocations: ["all"],
};
+ this.pointPrevLocations = ["all"];
this.handleQuery(1);
},
/** 閲嶇疆鎸夐挳鎿嶄綔 */
@@ -1693,8 +1724,9 @@
scopetype: [],
leaveldeptcodes: [],
leavehospitaldistrictcodes: [],
- pointLocations: [],
+ pointLocations: ["all"],
};
+ this.pointPrevLocations = ["all"];
},
handleSelectionChange(rows) {
this.selectedRows = rows.map((row) => {
diff --git a/src/views/sfstatistics/percentage/components/FirstFollowUp.vue b/src/views/sfstatistics/percentage/components/FirstFollowUp.vue
index c91b536..c6c3302 100644
--- a/src/views/sfstatistics/percentage/components/FirstFollowUp.vue
+++ b/src/views/sfstatistics/percentage/components/FirstFollowUp.vue
@@ -1256,6 +1256,14 @@
this.orgname == "绗竴浜烘皯鍖婚櫌鍚村北闄㈠尯"
);
},
+ // 绗竴浜烘皯鍖婚櫌涓変釜闄㈠尯锛氬強鏃剁巼鎸� 鍙婃椂瀹屾垚/闇�闅忚 璁$畻
+ isDiyiRenmin() {
+ return (
+ this.orgname == "绗竴浜烘皯鍖婚櫌婀栨花闄㈠尯" ||
+ this.orgname == "绗竴浜烘皯鍖婚櫌鍚村北闄㈠尯" ||
+ this.orgname == "绗竴浜烘皯鍖婚櫌鍩庝笢闄㈠尯"
+ );
+ },
},
methods: {
loadData() {
@@ -1380,8 +1388,24 @@
const rate = ((need - timeout) / need) * 100;
return (rate < 0 ? 0 : rate).toFixed(2) + "%";
},
- // 鍙婃椂鐜囧睍绀烘枃妗堬細鐩爣鍖婚櫌鍓嶇璁$畻锛屽叾浠栫敤鍚庣 rate 瀛楁
+ // 璁$畻鍙婃椂鐜囷紙绗竴浜烘皯鍖婚櫌涓夐櫌鍖猴級锛氬強鏃跺畬鎴� / 闇�闅忚
+ calculateTimelyRateByCompletion(timelyFollowUp, needFollowUp) {
+ const timely = Number(timelyFollowUp) || 0;
+ const need = Number(needFollowUp) || 0;
+ if (need <= 0) {
+ return "0.00%";
+ }
+ const rate = (timely / need) * 100;
+ return (rate < 0 ? 0 : rate).toFixed(2) + "%";
+ },
+ // 鍙婃椂鐜囧睍绀烘枃妗堬細绗竴浜烘皯鍖婚櫌涓夐櫌鍖哄墠绔寜鍙婃椂瀹屾垚/闇�闅忚锛岀洰鏍囧尰闄㈡寜(闇�闅忚-瓒呮椂)/闇�闅忚锛屽叾浠栫敤鍚庣 rate 瀛楁
getTimelyRateText(row) {
+ if (this.isDiyiRenmin) {
+ return this.calculateTimelyRateByCompletion(
+ row.timelyFollowUp,
+ row.needFollowUp
+ );
+ }
if (this.isTargetHospital) {
return this.calculateTimelyRate(
row.needFollowUp,
@@ -1429,7 +1453,20 @@
sums[index] = "0.00%";
}
} else if (column.property === "rate") {
- if (this.isTargetHospital) {
+ if (this.isDiyiRenmin) {
+ const totalTimely = data.reduce(
+ (sum, item) => sum + (Number(item.timelyFollowUp) || 0),
+ 0
+ );
+ const totalNeed = data.reduce(
+ (sum, item) => sum + (Number(item.needFollowUp) || 0),
+ 0
+ );
+ sums[index] = this.calculateTimelyRateByCompletion(
+ totalTimely,
+ totalNeed
+ );
+ } else if (this.isTargetHospital) {
const totalNeed = data.reduce(
(sum, item) => sum + (Number(item.needFollowUp) || 0),
0
@@ -1524,7 +1561,9 @@
"el-tooltip",
{
props: {
- content: this.isTargetHospital
+ content: this.isDiyiRenmin
+ ? "鍙婃椂鐜�=鍙婃椂瀹屾垚/闇�闅忚"
+ : this.isTargetHospital
? "鍙婃椂鐜�=(闇�闅忚-浜哄伐瑙勫畾鏃堕棿鍐呮病鎵撹繃鐢佃瘽)/闇�闅忚"
: "(鍑洪櫌鏃堕棿+浠诲姟鍛ㄦ湡)灏忎簬瀹屾垚鏃堕棿鍗充负瓒呮椂;(闇�闅忚-瓒呮椂)/闇�闅忚",
placement: "top",
@@ -1612,7 +1651,20 @@
sums[index] = "0.00%";
}
} else if (column.property === "rate") {
- if (this.isTargetHospital) {
+ if (this.isDiyiRenmin) {
+ const totalTimely = data.reduce(
+ (sum, item) => sum + (Number(item.timelyFollowUp) || 0),
+ 0
+ );
+ const totalNeed = data.reduce(
+ (sum, item) => sum + (Number(item.needFollowUp) || 0),
+ 0
+ );
+ sums[index] = this.calculateTimelyRateByCompletion(
+ totalTimely,
+ totalNeed
+ );
+ } else if (this.isTargetHospital) {
const totalNeed = data.reduce(
(sum, item) => sum + (Number(item.needFollowUp) || 0),
0
@@ -2142,9 +2194,21 @@
: "0.00%"
);
- // 鍙婃椂鐜囷紙鐩爣鍖婚櫌璁$畻锛屽叾浠栧彇 rate 骞冲潎锛�
+ // 鍙婃椂鐜囷紙绗竴浜烘皯鍖婚櫌涓夐櫌鍖烘寜鍙婃椂瀹屾垚/闇�闅忚锛岀洰鏍囧尰闄㈣绠楋紝鍏朵粬鍙� rate 骞冲潎锛�
if (showTimelyRate) {
- if (graded) {
+ if (this.isDiyiRenmin) {
+ const totalTimely = data.reduce(
+ (s, r) => s + (Number(r.timelyFollowUp) || 0),
+ 0
+ );
+ const totalNeed = data.reduce(
+ (s, r) => s + (Number(r.needFollowUp) || 0),
+ 0
+ );
+ sums.push(
+ this.calculateTimelyRateByCompletion(totalTimely, totalNeed)
+ );
+ } else if (graded) {
const totalNeed = data.reduce(
(s, r) => s + (Number(r.needFollowUp) || 0),
0
@@ -2661,8 +2725,17 @@
summaries[followUpRateIdx] = (avgFollowUpRate * 100).toFixed(2) + "%";
}
- // 鍙婃椂鐜囪绠楋細鐩爣鍖婚櫌 (闇�闅忚-浜哄伐瓒呮椂)/闇�闅忚锛屽叾浠栧彇鍚庣 rate 骞冲潎
- if (graded) {
+ // 鍙婃椂鐜囪绠楋細绗竴浜烘皯鍖婚櫌涓夐櫌鍖烘寜鍙婃椂瀹屾垚/闇�闅忚锛岀洰鏍囧尰闄� (闇�闅忚-浜哄伐瓒呮椂)/闇�闅忚锛屽叾浠栧彇鍚庣 rate 骞冲潎
+ if (this.isDiyiRenmin) {
+ const totalTimely = this.tableData.reduce(
+ (sum, item) => sum + (Number(item.timelyFollowUp) || 0),
+ 0
+ );
+ summaries[timelyRateIdx] = this.calculateTimelyRateByCompletion(
+ totalTimely,
+ totalNeed
+ );
+ } else if (graded) {
const totalTimeout = this.tableData.reduce(
(sum, item) => sum + (Number(item.manualCallTimeout) || 0),
0
diff --git "a/\351\232\217\350\256\277\351\200\232\347\224\25011.18 \0502\051.zip" "b/\351\232\217\350\256\277\351\200\232\347\224\25011.18 \0502\051.zip"
new file mode 100644
index 0000000..14f0d52
--- /dev/null
+++ "b/\351\232\217\350\256\277\351\200\232\347\224\25011.18 \0502\051.zip"
Binary files differ
diff --git "a/\351\232\217\350\256\277\351\200\232\347\224\25011.18.zip" "b/\351\232\217\350\256\277\351\200\232\347\224\25011.18.zip"
new file mode 100644
index 0000000..4955a16
--- /dev/null
+++ "b/\351\232\217\350\256\277\351\200\232\347\224\25011.18.zip"
Binary files differ
diff --git "a/\351\232\217\350\256\277\351\200\232\347\224\25011.19.zip" "b/\351\232\217\350\256\277\351\200\232\347\224\25011.19.zip"
new file mode 100644
index 0000000..5bf3a88
--- /dev/null
+++ "b/\351\232\217\350\256\277\351\200\232\347\224\25011.19.zip"
Binary files differ
--
Gitblit v1.9.3