From 61f0c5d3a9308d1eaefd8890a46b3c569707e050 Mon Sep 17 00:00:00 2001
From: WXL (wul) <wl_5969728@163.com>
Date: 星期四, 09 四月 2026 09:24:47 +0800
Subject: [PATCH] 测试完成

---
 src/views/Satisfaction/sfstatistics/components/SatisfactionStatistics.vue |   70 ++++++++++++++++++----------------
 1 files changed, 37 insertions(+), 33 deletions(-)

diff --git a/src/views/Satisfaction/sfstatistics/components/SatisfactionStatistics.vue b/src/views/Satisfaction/sfstatistics/components/SatisfactionStatistics.vue
index c1d3a0a..2d78fdf 100644
--- a/src/views/Satisfaction/sfstatistics/components/SatisfactionStatistics.vue
+++ b/src/views/Satisfaction/sfstatistics/components/SatisfactionStatistics.vue
@@ -414,7 +414,7 @@
                   </template>
                 </el-table-column>
 
-                <el-table-column
+                <!-- <el-table-column
                   label="瓒嬪娍"
                   prop="trend"
                   align="center"
@@ -446,7 +446,7 @@
                       }}</span>
                     </div>
                   </template>
-                </el-table-column>
+                </el-table-column> -->
 
                 <el-table-column
                   label="鎿嶄綔"
@@ -790,11 +790,11 @@
       Object.entries(apiData.rows).forEach(([typeName, typeStat]) => {
         const sendCount = typeStat.subidAll || 0;
         const receiveCount = typeStat.fillCountAll || 0;
-        const recoveryRate = typeStat.receiveRate || 0;
+        const recoveryRate = typeStat.receiveRate.toFixed(2) || 0;
 
         chartData.push({
           name: typeName,
-          value: recoveryRate * 100, // 杞崲涓虹櫨鍒嗘瘮
+          value: (recoveryRate * 100).toFixed(2), // 杞崲涓虹櫨鍒嗘瘮
           sendCount: sendCount,
           receiveCount: receiveCount,
           averageScore: typeStat.averageScore || 0,
@@ -914,7 +914,9 @@
         const response = await satisfactionGraph(params);
 
         if (response.code === 200) {
-          this.processTypeDetailData(response.data);
+          this.processTypeDetailData(response);
+          console.log(11);
+
         } else {
           this.$message.error(response.msg || "鑾峰彇绫诲瀷鏄庣粏鏁版嵁澶辫触");
           const mockData = await this.generateMockTypeDetail();
@@ -944,7 +946,7 @@
       Object.entries(apiData.rows).forEach(([typeName, typeStat], index) => {
         const sendCount = typeStat.subidAll || 0;
         const receiveCount = typeStat.fillCountAll || 0;
-        const recoveryRate = typeStat.receiveRate || 0;
+        const recoveryRate = typeStat.receiveRate.toFixed(2) || 0;
         const averageScore = typeStat.averageScore || 0;
 
         typeDetail.push({
@@ -963,6 +965,8 @@
       });
 
       this.typeDetailData = typeDetail;
+      console.log(this.typeDetailData,'this.typeDetailData');
+
       this.calculateTypeSummary(typeDetail);
     },
 
@@ -972,7 +976,7 @@
       if (score >= 4.0) return "鑹ソ";
       if (score >= 3.0) return "涓�鑸�";
       if (score >= 2.0) return "杈冨樊";
-      return "宸�";
+      return "鏈煡";
     },
 
     // 鑾峰彇瓒嬪娍
@@ -1041,24 +1045,24 @@
     // 娓叉煋鍥捐〃
     renderChart(chartData) {
       if (!this.barChart) return;
- if (!chartData || chartData.length === 0) {
-    const emptyOption = {
-      title: {
-        text: "鏆傛棤鏁版嵁",
-        left: "center",
-        top: "center",
-        textStyle: {
-          color: "#999",
-          fontSize: 16,
-          fontWeight: "normal"
-        }
-      },
-      xAxis: { show: false },
-      yAxis: { show: false }
-    };
-    this.barChart.setOption(emptyOption);
-    return;
-  }
+      if (!chartData || chartData.length === 0) {
+        const emptyOption = {
+          title: {
+            text: "鏆傛棤鏁版嵁",
+            left: "center",
+            top: "center",
+            textStyle: {
+              color: "#999",
+              fontSize: 16,
+              fontWeight: "normal",
+            },
+          },
+          xAxis: { show: false },
+          yAxis: { show: false },
+        };
+        this.barChart.setOption(emptyOption);
+        return;
+      }
       const option = {
         title: {
           text: "",
@@ -1079,7 +1083,7 @@
                 <span style="display:inline-block;width:10px;height:10px;border-radius:2px;background:${
                   data.color
                 };margin-right:5px;"></span>
-                濉姤姣斾緥: <strong>${data.value.toFixed(1)}%</strong>
+                濉姤姣斾緥: <strong>${data.value}%</strong>
               </div>
               <div style="margin: 2px 0;">
                 <span style="display:inline-block;width:10px;height:10px;border-radius:2px;background:#eee;margin-right:5px;"></span>
@@ -1437,12 +1441,12 @@
 
     // 鏍煎紡鍖栫櫨鍒嗘瘮
     formatPercent(value) {
-   if (value === null || value === undefined) return "-";
-  const num = parseFloat(value);
-  if (isNaN(num)) return "-";
-  // 濡傛灉鍊煎皬浜�1锛岃涓烘槸灏忔暟姣斾緥锛岄渶瑕佷箻浠�100
-  const percentValue = num < 1 ? num * 100 : num;
-  return `${percentValue.toFixed(2)}%`;
+      if (value === null || value === undefined) return "-";
+      const num = parseFloat(value);
+      if (isNaN(num)) return "-";
+      // 濡傛灉鍊煎皬浜�1锛岃涓烘槸灏忔暟姣斾緥锛岄渶瑕佷箻浠�100
+      const percentValue = num < 1 ? num * 100 : num;
+      return `${percentValue.toFixed(2)}%`;
     },
 
     // 鑾峰彇鍥炴敹鐜囨牱寮忕被
@@ -1459,7 +1463,7 @@
         鑹ソ: "primary",
         涓�鑸�: "warning",
         杈冨樊: "danger",
-        宸�: "info",
+        鏈煡: "info",
       };
       return levelMap[level] || "info";
     },

--
Gitblit v1.9.3