From b4fe2c16274a91fee4fb26d91374f95fbe2dbcec Mon Sep 17 00:00:00 2001
From: WXL (wul) <wl_5969728@163.com>
Date: 星期一, 09 十一月 2026 15:28:21 +0800
Subject: [PATCH] 测试完成
---
src/views/sfstatistics/percentage/components/SecondFollowUp.vue | 550 ++++++++++++++++++++++++++++++++++++++----------------
1 files changed, 387 insertions(+), 163 deletions(-)
diff --git a/src/views/sfstatistics/percentage/components/SecondFollowUp.vue b/src/views/sfstatistics/percentage/components/SecondFollowUp.vue
index f49c5f4..e675bef 100644
--- a/src/views/sfstatistics/percentage/components/SecondFollowUp.vue
+++ b/src/views/sfstatistics/percentage/components/SecondFollowUp.vue
@@ -154,6 +154,7 @@
</template>
</el-table-column>
<el-table-column
+ v-if="!isTargetHospital"
label="寰呴殢璁�"
align="center"
key="pendingFollowUpAgain"
@@ -177,6 +178,62 @@
}}</span>
</el-button>
</template>
+ </el-table-column>
+ <el-table-column
+ v-if="isTargetHospital"
+ label="寰呴殢璁�"
+ align="center"
+ >
+ <el-table-column
+ label="寰呭彂閫�"
+ align="center"
+ key="pendingFollowUpWaitSendAgain"
+ prop="pendingFollowUpWaitSendAgain"
+ >
+ <template slot-scope="scope">
+ <el-button
+ size="medium"
+ type="text"
+ @click="
+ handleViewDetails(
+ scope.row,
+ 'pendingFollowUpWaitSendAgainInfo',
+ '寰呭彂閫佸垪琛�',
+ '1'
+ )
+ "
+ >
+ <span class="button-zx">{{
+ scope.row.pendingFollowUpWaitSendAgain
+ }}</span>
+ </el-button>
+ </template>
+ </el-table-column>
+ <el-table-column
+ label="宸插彂閫�"
+ align="center"
+ key="pendingFollowUpSentAgain"
+ prop="pendingFollowUpSentAgain"
+ >
+ <template slot-scope="scope">
+ <el-button
+ size="medium"
+ type="text"
+ @click="
+ handleViewDetails(
+ scope.row,
+ 'pendingFollowUpSentAgainInfo',
+ '宸插彂閫佸垪琛�',
+ '1'
+ )
+ "
+ >
+ <span class="button-zx">{{
+ scope.row.pendingFollowUpSentAgain
+ }}</span>
+ </el-button>
+ </template>
+ </el-table-column>
</el-table-column>
<el-table-column
label="闅忚鎴愬姛"
@@ -204,6 +261,7 @@
</template>
</el-table-column>
<el-table-column
+ v-if="!isTargetHospital"
label="闅忚澶辫触"
align="center"
key="followUpFailAgain"
@@ -457,6 +515,7 @@
</template>
</el-table-column>
<el-table-column
+ v-if="!isTargetHospital"
label="寰呴殢璁�"
align="center"
key="pendingFollowUpAgain"
@@ -479,6 +538,60 @@
}}</span>
</el-button>
</template>
+ </el-table-column>
+ <el-table-column
+ v-if="isTargetHospital"
+ label="寰呴殢璁�"
+ align="center"
+ >
+ <el-table-column
+ label="寰呭彂閫�"
+ align="center"
+ key="pendingFollowUpWaitSendAgain"
+ prop="pendingFollowUpWaitSendAgain"
+ >
+ <template slot-scope="scope">
+ <el-button
+ size="medium"
+ type="text"
+ @click="
+ handleViewDetails(
+ scope.row,
+ 'pendingFollowUpWaitSendAgainInfo',
+ '鍐嶆闅忚寰呭彂閫佸垪琛�'
+ )
+ "
+ >
+ <span class="button-zx">{{
+ scope.row.pendingFollowUpWaitSendAgain
+ }}</span>
+ </el-button>
+ </template>
+ </el-table-column>
+ <el-table-column
+ label="宸插彂閫�"
+ align="center"
+ key="pendingFollowUpSentAgain"
+ prop="pendingFollowUpSentAgain"
+ >
+ <template slot-scope="scope">
+ <el-button
+ size="medium"
+ type="text"
+ @click="
+ handleViewDetails(
+ scope.row,
+ 'pendingFollowUpSentAgainInfo',
+ '鍐嶆闅忚宸插彂閫佸垪琛�'
+ )
+ "
+ >
+ <span class="button-zx">{{
+ scope.row.pendingFollowUpSentAgain
+ }}</span>
+ </el-button>
+ </template>
+ </el-table-column>
</el-table-column>
<el-table-column
label="闅忚鎴愬姛"
@@ -505,6 +618,7 @@
</template>
</el-table-column>
<el-table-column
+ v-if="!isTargetHospital"
label="闅忚澶辫触"
align="center"
key="followUpFailAgain"
@@ -553,67 +667,40 @@
prop="followUpRateAgain"
:render-header="Tooltipsfl"
/>
+
<el-table-column
- v-if="isTargetHospital"
- label="浜哄伐"
+ v-if="orgname == '缂欎簯鍘夸汉姘戝尰闄�'"
+ label="澶嶈瘖澶嶆煡鏁伴噺"
align="center"
+ key="suggest7CountAgain"
+ prop="suggest7CountAgain"
>
- <el-table-column
- label="鍙戦�佸畬鎴�"
- align="center"
- key="manualAgain"
- prop="manualAgain"
- :render-header="Tooltipfswc"
- >
- <template slot-scope="scope">
- <el-button
- size="medium"
- type="text"
- @click="
- handleViewDetails(
- scope.row,
- 'manualAgainInfo',
- '鍙戦�佸畬鎴愪汉宸ラ殢璁垮垪琛�'
- )
- "
- >
- <span class="button-zx">{{ scope.row.manualAgain }}</span>
- </el-button>
- </template>
- </el-table-column>
- <el-table-column
- label="鏈�缁堝畬鎴�"
- align="center"
- key="manualAgainSuccess"
- prop="manualAgainSuccess"
- :render-header="Tooltipzzwc"
- >
- <template slot-scope="scope">
- <el-button
- size="medium"
- type="text"
- @click="
- handleViewDetails(
- scope.row,
- 'manualAgainSuccessInfo',
- '鏈�缁堝畬鎴愪汉宸ラ殢璁垮垪琛�'
- )
- "
- >
- <span class="button-zx">{{
- scope.row.manualAgainSuccess
- }}</span>
- </el-button>
- </template>
- </el-table-column>
+ <template slot-scope="scope">
+ <el-button
+ size="medium"
+ type="text"
+ @click="
+ handleViewDetails(
+ scope.row,
+ 'suggest7CountAgainInfo',
+ '鍐嶆闅忚澶嶈瘖澶嶆煡鍒楄〃'
+ )
+ "
+ >
+ <span class="button-zx">{{
+ scope.row.suggest7CountAgain
+ }}</span>
+ </el-button>
+ </template>
</el-table-column>
+
<el-table-column
v-if="isTargetHospital"
label="璇煶"
align="center"
>
<el-table-column
- label="鍙戦�佸畬鎴�"
+ label="鍙戦�佹暟"
align="center"
key="voiceAgain"
prop="voiceAgain"
@@ -636,7 +723,7 @@
</template>
</el-table-column>
<el-table-column
- label="鏈�缁堝畬鎴�"
+ label="鎴愬姛鏁�"
align="center"
key="voiceAgainSuccess"
prop="voiceAgainSuccess"
@@ -661,13 +748,67 @@
</template>
</el-table-column>
</el-table-column>
+ <el-table-column
+ v-if="isTargetHospital"
+ label="寰俊"
+ align="center"
+ >
+ <el-table-column
+ label="鍙戦�佹暟"
+ align="center"
+ key="weChatAgain"
+ prop="weChatAgain"
+ :render-header="Tooltipfswc"
+ >
+ <template slot-scope="scope">
+ <el-button
+ size="medium"
+ type="text"
+ @click="
+ handleViewDetails(
+ scope.row,
+ 'weChatAgainInfo',
+ '鍙戦�佸畬鎴愬井淇¢殢璁垮垪琛�'
+ )
+ "
+ >
+ <span class="button-zx">{{ scope.row.weChatAgain }}</span>
+ </el-button>
+ </template>
+ </el-table-column>
+ <el-table-column
+ label="鎴愬姛鏁�"
+ align="center"
+ key="weChatAgainSuccess"
+ prop="weChatAgainSuccess"
+ :render-header="Tooltipzzwc"
+ >
+ <template slot-scope="scope">
+ <el-button
+ size="medium"
+ type="text"
+ @click="
+ handleViewDetails(
+ scope.row,
+ 'wechatAgainSuccessInfo',
+ '鏈�缁堝畬鎴愬井淇¢殢璁垮垪琛�'
+ )
+ "
+ >
+ <span class="button-zx">{{
+ scope.row.weChatAgainSuccess
+ }}</span>
+ </el-button>
+ </template>
+ </el-table-column>
+ </el-table-column>
<el-table-column
v-if="isTargetHospital"
label="鐭俊"
align="center"
>
<el-table-column
- label="鍙戦�佸畬鎴�"
+ label="鍙戦�佹暟"
align="center"
key="smsAgain"
prop="smsAgain"
@@ -690,7 +831,7 @@
</template>
</el-table-column>
<el-table-column
- label="鏈�缁堝畬鎴�"
+ label="鎴愬姛鏁�"
align="center"
key="smsAgainSuccess"
prop="smsAgainSuccess"
@@ -715,16 +856,17 @@
</template>
</el-table-column>
</el-table-column>
- <el-table-column
+
+ <el-table-column
v-if="isTargetHospital"
- label="寰俊"
+ label="浜哄伐"
align="center"
>
<el-table-column
- label="鍙戦�佸畬鎴�"
+ label="鍙戦�佹暟"
align="center"
- key="weChatAgain"
- prop="weChatAgain"
+ key="manualAgain"
+ prop="manualAgain"
:render-header="Tooltipfswc"
>
<template slot-scope="scope">
@@ -734,20 +876,20 @@
@click="
handleViewDetails(
scope.row,
- 'weChatAgainInfo',
- '鍙戦�佸畬鎴愬井淇¢殢璁垮垪琛�'
+ 'manualAgainInfo',
+ '鍙戦�佸畬鎴愪汉宸ラ殢璁垮垪琛�'
)
"
>
- <span class="button-zx">{{ scope.row.weChatAgain }}</span>
+ <span class="button-zx">{{ scope.row.manualAgain }}</span>
</el-button>
</template>
</el-table-column>
<el-table-column
- label="鏈�缁堝畬鎴�"
+ label="鎴愬姛鏁�"
align="center"
- key="weChatAgainSuccess"
- prop="weChatAgainSuccess"
+ key="manualAgainSuccess"
+ prop="manualAgainSuccess"
:render-header="Tooltipzzwc"
>
<template slot-scope="scope">
@@ -757,13 +899,13 @@
@click="
handleViewDetails(
scope.row,
- 'wechatAgainSuccessInfo',
- '鏈�缁堝畬鎴愬井淇¢殢璁垮垪琛�'
+ 'manualAgainSuccessInfo',
+ '鏈�缁堝畬鎴愪汉宸ラ殢璁垮垪琛�'
)
"
>
<span class="button-zx">{{
- scope.row.weChatAgainSuccess
+ scope.row.manualAgainSuccess
}}</span>
</el-button>
</template>
@@ -946,7 +1088,9 @@
"el-tooltip",
{
props: {
- content: "闅忚鎴愬姛/(闇�闅忚-寰呴殢璁�)",
+ content: this.isTargetHospital
+ ? "闅忚鎴愬姛/闇�闅忚"
+ : "闅忚鎴愬姛/(闇�闅忚-寰呴殢璁�)",
placement: "top",
effect: "dark",
},
@@ -1103,7 +1247,7 @@
return sum + (Number(item.pendingFollowUpAgain) || 0);
}, 0);
- const denominator = totalNeed - totalPending;
+ const denominator = this.isTargetHospital ? totalNeed : totalNeed - totalPending;
if (denominator > 0) {
sums[index] = ((totalSuccess / denominator) * 100).toFixed(2) + "%";
@@ -1181,7 +1325,7 @@
return sum + (Number(item.pendingFollowUpAgain) || 0);
}, 0);
- const denominator = totalNeed - totalPending;
+ const denominator = this.isTargetHospital ? totalNeed : totalNeed - totalPending;
if (denominator > 0) {
sums[index] = ((totalSuccess / denominator) * 100).toFixed(2) + "%";
@@ -1312,8 +1456,8 @@
const need = Number(needFollowUp) || 0;
const pending = Number(pendingFollowUp) || 0;
- // 鍒嗘瘝 = 闇�闅忚 - 寰呴殢璁�
- const denominator = need - pending;
+ // 鍒嗘瘝 = 闇�闅忚锛堢洰鏍囧尰闄級/ 闇�闅忚 - 寰呴殢璁匡紙鍏朵粬锛�
+ const denominator = this.isTargetHospital ? need : need - pending;
if (denominator <= 0) {
return "0.00%";
@@ -1535,13 +1679,11 @@
},
};
- // 鏍囬
- worksheet.mergeCells(1, 1, 1, 10);
- worksheet.getCell(1, 1).value = `${areaName}鍖荤敓鍐嶆闅忚鍒楄〃`;
- worksheet.getCell(1, 1).style = titleStyle;
- worksheet.getRow(1).height = 30;
+ const graded = this.isTargetHospital;
+ // 鎴愬姛鐜囷細鏅畞鐣叉棌鑷不鍘夸汉姘戝尰闄笉灞曠ず
+ const showSuccessRate = this.orgname != "鏅畞鐣叉棌鑷不鍘夸汉姘戝尰闄�";
- // 琛ㄥご
+ // 鍒楀畾涔夛紙涓庡睍寮�鐨勫尰鐢熷瓙琛ㄤ繚鎸佷竴鑷达級
const headers = [
"鍖荤敓濮撳悕",
"绉戝",
@@ -1549,13 +1691,25 @@
"鏃犻渶闅忚",
"搴旈殢璁�",
"闇�闅忚",
- "寰呴殢璁�",
+ ...(graded ? ["寰呭彂閫�", "宸插彂閫�"] : ["寰呴殢璁�"]),
"闅忚鎴愬姛",
- "闅忚澶辫触",
- "鎴愬姛鐜�", // 鏂板
- "闅忚鐜�", // 鍘熸潵鍦ㄦ垚鍔熺巼浣嶇疆
+ ...(graded ? [] : ["闅忚澶辫触"]),
+ ...(showSuccessRate ? ["鎴愬姛鐜�"] : []),
+ "闅忚鐜�",
+ "浜哄伐",
+ "璇煶",
+ "鐭俊",
+ "寰俊",
];
+ const totalCols = headers.length;
+ // 鏍囬
+ worksheet.mergeCells(1, 1, 1, totalCols);
+ worksheet.getCell(1, 1).value = `${areaName}鍖荤敓鍐嶆闅忚鍒楄〃`;
+ worksheet.getCell(1, 1).style = titleStyle;
+ worksheet.getRow(1).height = 30;
+
+ // 琛ㄥご
const headerRow = worksheet.addRow(headers);
headerRow.eachCell((cell) => {
cell.style = headerStyle;
@@ -1571,15 +1725,28 @@
item.nonFollowUp,
item.followUpNeeded,
item.needFollowUpAgain,
- item.pendingFollowUpAgain,
+ ...(graded
+ ? [
+ item.pendingFollowUpWaitSendAgain || 0,
+ item.pendingFollowUpSentAgain || 0,
+ ]
+ : [item.pendingFollowUpAgain || 0]),
item.followUpSuccessAgain,
- item.followUpFailAgain,
- this.calculateSuccessRate(
- item.followUpSuccessAgain,
- item.needFollowUpAgain,
- item.pendingFollowUpAgain
- ),
+ ...(graded ? [] : [item.followUpFailAgain || 0]),
+ ...(showSuccessRate
+ ? [
+ this.calculateSuccessRate(
+ item.followUpSuccessAgain,
+ item.needFollowUpAgain,
+ item.pendingFollowUpAgain
+ ),
+ ]
+ : []),
item.followUpRateAgain,
+ item.manualAgain || 0,
+ item.voiceAgain || 0,
+ item.smsAgain || 0,
+ item.weChatAgain || 0,
]);
row.eachCell((cell) => {
cell.style = cellStyle;
@@ -1599,33 +1766,28 @@
};
});
- // 鍒楀
- worksheet.columns = [
- { width: 15 },
- { width: 15 },
- { width: 12 },
- { width: 12 },
- { width: 12 },
- { width: 12 },
- { width: 12 },
- { width: 12 },
- { width: 12 },
- { width: 12 }, // 鎴愬姛鐜�
- { width: 12 }, // 闅忚鐜�
- ];
+ // 鍒楀锛堝墠涓ゅ垪濮撳悕/绉戝杈冨锛屽叾浣欑粺涓�锛�
+ const widths = [15, 15];
+ headers.slice(2).forEach(() => widths.push(12));
+ worksheet.columns = widths.map((width) => ({ width }));
},
/** 鍐嶆闅忚 - 鍖荤敓瀛愯〃瀵煎嚭灏忚 */
getDoctorAgainExportSummary(data) {
- const sums = ["灏忚"];
+ const graded = this.isTargetHospital;
+ const showSuccessRate = this.orgname != "鏅畞鐣叉棌鑷不鍘夸汉姘戝尰闄�";
+
+ const sums = ["灏忚", "-"];
const keys = [
"dischargeCount",
"nonFollowUp",
"followUpNeeded",
"needFollowUpAgain",
- "pendingFollowUpAgain",
+ ...(graded
+ ? ["pendingFollowUpWaitSendAgain", "pendingFollowUpSentAgain"]
+ : ["pendingFollowUpAgain"]),
"followUpSuccessAgain",
- "followUpFailAgain",
+ ...(graded ? [] : ["followUpFailAgain"]),
];
keys.forEach((key) => {
@@ -1633,25 +1795,28 @@
});
// 鎴愬姛鐜囷紙骞冲潎鍊硷級
- const successRates = data
- .map((item) => {
- const success = Number(item.followUpSuccessAgain) || 0;
- const need = Number(item.needFollowUpAgain) || 0;
- const pending = Number(item.pendingFollowUpAgain) || 0;
- const denominator = need - pending;
- if (denominator <= 0) return 0;
- return success / denominator;
- })
- .filter((rate) => !isNaN(rate));
+ if (showSuccessRate) {
+ const successRates = data
+ .map((item) => {
+ const success = Number(item.followUpSuccessAgain) || 0;
+ const need = Number(item.needFollowUpAgain) || 0;
+ const pending = Number(item.pendingFollowUpAgain) || 0;
+ const denominator = graded ? need : need - pending;
+ if (denominator <= 0) return 0;
+ return success / denominator;
+ })
+ .filter((rate) => !isNaN(rate));
- sums.push(
- successRates.length
- ? (
- (successRates.reduce((a, b) => a + b, 0) / successRates.length) *
- 100
- ).toFixed(2) + "%"
- : "0.00%"
- );
+ sums.push(
+ successRates.length
+ ? (
+ (successRates.reduce((a, b) => a + b, 0) /
+ successRates.length) *
+ 100
+ ).toFixed(2) + "%"
+ : "0.00%"
+ );
+ }
// 闅忚鐜囷紙骞冲潎鍊硷級
const followUpRates = data
@@ -1666,6 +1831,13 @@
100
).toFixed(2) + "%"
: "0.00%"
+ );
+
+ // 浜哄伐/璇煶/鐭俊/寰俊
+ ["manualAgain", "voiceAgain", "smsAgain", "weChatAgain"].forEach(
+ (key) => {
+ sums.push(data.reduce((t, r) => t + (Number(r[key]) || 0), 0));
+ }
);
return sums;
@@ -1745,7 +1917,7 @@
},
};
- // 鏄惁涓虹洰鏍囧尰闄紙浜哄伐/璇煶/鐭俊/寰俊 鎸� 鍙戦�佸畬鎴�/鏈�缁堝畬鎴� 鍒嗙骇灞曠ず锛�
+ // 鏄惁涓虹洰鏍囧尰闄紙浜哄伐/璇煶/鐭俊/寰俊 鎸� 鍙戦�佹暟/鎴愬姛鏁� 鍒嗙骇灞曠ず锛�
const graded = this.isTargetHospital;
const baseHeaders = [
@@ -1758,9 +1930,9 @@
];
const coreHeaders = [
"闇�闅忚",
- "寰呴殢璁�",
+ ...(this.isTargetHospital ? ["寰呭彂閫�", "宸插彂閫�"] : ["寰呴殢璁�"]),
"闅忚鎴愬姛",
- "闅忚澶辫触",
+ ...(this.isTargetHospital ? [] : ["闅忚澶辫触"]),
"鎴愬姛鐜�",
"闅忚鐜�",
];
@@ -1799,14 +1971,37 @@
worksheet.getCell(2, coreStartCol).value = "鍐嶆鍑洪櫌闅忚";
worksheet.getCell(2, coreStartCol).style = headerStyle;
- // 绗�3琛岋細闅忚鏍稿績鍒楃旱鍚戝悎骞� + 闅忚鏂瑰紡鍒嗙粍妯悜鍚堝苟
- for (let k = 0; k < coreCount; k++) {
- const col = coreStartCol + k;
+ // 绗�3琛岋細闅忚鏍稿績鍒楋紙鐩爣鍖婚櫌鈥滃緟闅忚鈥濅笅宓屽鈥滃緟鍙戦��/宸插彂閫佲�濓級
+ worksheet.mergeCells(3, coreStartCol, headerEndRow, coreStartCol);
+ worksheet.getCell(3, coreStartCol).value = "闇�闅忚";
+ worksheet.getCell(3, coreStartCol).style = headerStyle;
+
+ worksheet.mergeCells(3, coreStartCol + 1, 3, coreStartCol + 2);
+ worksheet.getCell(3, coreStartCol + 1).value = "寰呴殢璁�";
+ worksheet.getCell(3, coreStartCol + 1).style = headerStyle;
+
+ worksheet.mergeCells(
+ 3,
+ coreStartCol + 3,
+ headerEndRow,
+ coreStartCol + 3
+ );
+ worksheet.getCell(3, coreStartCol + 3).value = "闅忚鎴愬姛";
+ worksheet.getCell(3, coreStartCol + 3).style = headerStyle;
+
+ ["鎴愬姛鐜�", "闅忚鐜�"].forEach((label, i) => {
+ const col = coreStartCol + 4 + i;
worksheet.mergeCells(3, col, headerEndRow, col);
- const cell = worksheet.getCell(3, col);
- cell.value = coreHeaders[k];
- cell.style = headerStyle;
- }
+ worksheet.getCell(3, col).value = label;
+ worksheet.getCell(3, col).style = headerStyle;
+ });
+
+ // 绗�4琛岋細寰呭彂閫�/宸插彂閫� 瀛愬垪
+ worksheet.getCell(4, coreStartCol + 1).value = "寰呭彂閫�";
+ worksheet.getCell(4, coreStartCol + 1).style = headerStyle;
+ worksheet.getCell(4, coreStartCol + 2).value = "宸插彂閫�";
+ worksheet.getCell(4, coreStartCol + 2).style = headerStyle;
+
let mc = methodStartCol;
methodGroups.forEach((g) => {
if (g.fields.length > 1) {
@@ -1818,7 +2013,7 @@
mc += g.fields.length;
});
- // 绗�4琛岋細闅忚鏂瑰紡瀛愬垪锛堝彂閫佸畬鎴�/鏈�缁堝畬鎴愶級
+ // 绗�4琛岋細闅忚鏂瑰紡瀛愬垪锛堝彂閫佹暟/鎴愬姛鏁帮級
mc = methodStartCol;
methodGroups.forEach((g) => {
g.fields.forEach((field, idx) => {
@@ -1875,9 +2070,14 @@
item.nonFollowUp || 0,
item.followUpNeeded || 0,
item.needFollowUpAgain || 0,
- item.pendingFollowUpAgain || 0,
+ ...(this.isTargetHospital
+ ? [
+ item.pendingFollowUpWaitSendAgain || 0,
+ item.pendingFollowUpSentAgain || 0,
+ ]
+ : [item.pendingFollowUpAgain || 0]),
item.followUpSuccessAgain || 0,
- item.followUpFailAgain || 0,
+ ...(this.isTargetHospital ? [] : [item.followUpFailAgain || 0]),
// 鎴愬姛鐜� - 闇�瑕佸姩鎬佽绠�
this.calculateSuccessRate(
item.followUpSuccessAgain,
@@ -1918,13 +2118,13 @@
worksheet.columns = widths.map((width) => ({ width }));
},
getMethodColumns() {
- // 闅忚鏂瑰紡鍒楅厤缃細鐩爣鍖婚櫌鎸夆�滃彂閫佸畬鎴�/鏈�缁堝畬鎴愨�濆垎绾у睍绀�
+ // 闅忚鏂瑰紡鍒楅厤缃細鐩爣鍖婚櫌鎸夆�滃彂閫佹暟/鎴愬姛鏁扳�濆垎绾у睍绀�
if (this.isTargetHospital) {
return [
- { label: "浜哄伐", fields: ["manualAgain", "manualAgainSuccess"], sub: ["鍙戦�佸畬鎴�", "鏈�缁堝畬鎴�"] },
- { label: "璇煶", fields: ["voiceAgain", "voiceAgainSuccess"], sub: ["鍙戦�佸畬鎴�", "鏈�缁堝畬鎴�"] },
- { label: "鐭俊", fields: ["smsAgain", "smsAgainSuccess"], sub: ["鍙戦�佸畬鎴�", "鏈�缁堝畬鎴�"] },
- { label: "寰俊", fields: ["weChatAgain", "weChatAgainSuccess"], sub: ["鍙戦�佸畬鎴�", "鏈�缁堝畬鎴�"] },
+ { label: "浜哄伐", fields: ["manualAgain", "manualAgainSuccess"], sub: ["鍙戦�佹暟", "鎴愬姛鏁�"] },
+ { label: "璇煶", fields: ["voiceAgain", "voiceAgainSuccess"], sub: ["鍙戦�佹暟", "鎴愬姛鏁�"] },
+ { label: "鐭俊", fields: ["smsAgain", "smsAgainSuccess"], sub: ["鍙戦�佹暟", "鎴愬姛鏁�"] },
+ { label: "寰俊", fields: ["weChatAgain", "weChatAgainSuccess"], sub: ["鍙戦�佹暟", "鎴愬姛鏁�"] },
];
}
return [
@@ -1936,20 +2136,35 @@
},
getExportSummaries() {
- const summaries = [
- "鍚堣",
- "/",
- "/",
- 0, // 3: dischargeCount
- 0, // 4: nonFollowUp
- 0, // 5: followUpNeeded
- 0, // 6: needFollowUpAgain
- 0, // 7: pendingFollowUpAgain
- 0, // 8: followUpSuccessAgain
- 0, // 9: followUpFailAgain
- "0%", // 10: 鎴愬姛鐜�
- "0%", // 11: 闅忚鐜�
- ];
+ const summaries = this.isTargetHospital
+ ? [
+ "鍚堣",
+ "/",
+ "/",
+ 0, // 3: dischargeCount
+ 0, // 4: nonFollowUp
+ 0, // 5: followUpNeeded
+ 0, // 6: needFollowUpAgain
+ 0, // 7: pendingFollowUpWaitSendAgain
+ 0, // 8: pendingFollowUpSentAgain
+ 0, // 9: followUpSuccessAgain
+ "0%", // 10: 鎴愬姛鐜�
+ "0%", // 11: 闅忚鐜�
+ ]
+ : [
+ "鍚堣",
+ "/",
+ "/",
+ 0, // 3: dischargeCount
+ 0, // 4: nonFollowUp
+ 0, // 5: followUpNeeded
+ 0, // 6: needFollowUpAgain
+ 0, // 7: pendingFollowUpAgain
+ 0, // 8: followUpSuccessAgain
+ 0, // 9: followUpFailAgain
+ "0%", // 10: 鎴愬姛鐜�
+ "0%", // 11: 闅忚鐜�
+ ];
const methodFields = this.getMethodColumns().reduce(
(arr, g) => arr.concat(g.fields),
@@ -1963,19 +2178,28 @@
summaries[4] += Number(item.nonFollowUp) || 0;
summaries[5] += Number(item.followUpNeeded) || 0;
summaries[6] += Number(item.needFollowUpAgain) || 0;
- summaries[7] += Number(item.pendingFollowUpAgain) || 0;
- summaries[8] += Number(item.followUpSuccessAgain) || 0;
- summaries[9] += Number(item.followUpFailAgain) || 0;
+ if (this.isTargetHospital) {
+ summaries[7] += Number(item.pendingFollowUpWaitSendAgain) || 0;
+ summaries[8] += Number(item.pendingFollowUpSentAgain) || 0;
+ summaries[9] += Number(item.followUpSuccessAgain) || 0;
+ } else {
+ summaries[7] += Number(item.pendingFollowUpAgain) || 0;
+ summaries[8] += Number(item.followUpSuccessAgain) || 0;
+ summaries[9] += Number(item.followUpFailAgain) || 0;
+ }
methodFields.forEach((field, i) => {
summaries[methodStartIndex + i] += Number(item[field]) || 0;
});
});
// 鎴愬姛鐜囪绠�
- const totalSuccess = summaries[8]; // followUpSuccessAgain鐨勬�诲拰
+ const totalSuccess = this.isTargetHospital
+ ? summaries[9] // followUpSuccessAgain鐨勬�诲拰
+ : summaries[8]; // followUpSuccessAgain鐨勬�诲拰
const totalNeed = summaries[6]; // needFollowUpAgain鐨勬�诲拰
- const totalPending = summaries[7]; // pendingFollowUpAgain鐨勬�诲拰
- const denominator = totalNeed - totalPending;
+ const denominator = this.isTargetHospital
+ ? totalNeed
+ : totalNeed - summaries[7];
if (denominator > 0) {
summaries[10] = ((totalSuccess / denominator) * 100).toFixed(2) + "%";
--
Gitblit v1.9.3