From 16913ea709f434cfebe71fd0c66b0a6931398f3e Mon Sep 17 00:00:00 2001
From: ludc
Date: 星期三, 13 十二月 2023 08:56:57 +0800
Subject: [PATCH] Merge remote-tracking branch 'origin/master'

---
 Source/UBCS-WEB/src/components/StatisticsComponent/lineChart.vue |   29 +++++++++++++++++------------
 1 files changed, 17 insertions(+), 12 deletions(-)

diff --git a/Source/UBCS-WEB/src/components/StatisticsComponent/lineChart.vue b/Source/UBCS-WEB/src/components/StatisticsComponent/lineChart.vue
index fcc9ab9..f37802e 100644
--- a/Source/UBCS-WEB/src/components/StatisticsComponent/lineChart.vue
+++ b/Source/UBCS-WEB/src/components/StatisticsComponent/lineChart.vue
@@ -31,13 +31,15 @@
       handler(newval, oldval) {
         if (newval) {
           const series = newval.map((data, index) => ({
-            name: index === 0 ? "鎬婚噺" : "鏂板",
-            type: "line",
+            name: index === 0 ? '鎬婚噺' : '鏂板',
+            type: 'line',
             smooth: true,
-            stack: "Total",
+            stack: index === 0 ? 'Total' : 'total2', // 鏍规嵁 index 鍖哄垎鎬婚噺鍜屾柊澧炵殑鍫嗗彔鎯呭喌
             label: {
               show: true,
-              position: "top"
+              textStyle: {
+                fontSize: 14
+              }
             },
             data: data.map(value => ({value}))
           }));
@@ -46,14 +48,14 @@
         }
       }
     },
-    chartName:{
-      handler(newval,oldval){
-        if(newval){
+    chartName: {
+      handler(newval, oldval) {
+        if (newval) {
           this.chartOptions.title.text = newval + "鏁版嵁缁熻"
         }
       },
-      immediate:true,
-      deep:true
+      immediate: true,
+      deep: true
     }
   },
   data() {
@@ -67,15 +69,18 @@
           trigger: 'axis'
         },
         legend: {
-          data: ['鎬婚噺', '鏂板']
+          data: ['鎬婚噺', '鏂板'],
+          textStyle: {
+            fontSize: 14 // 璋冩暣瀛椾綋澶у皬
+          }
         },
         xAxis: {
           boundaryGap: true,
           type: 'category',
-          data: ['1鏈�', '2鏈�', '3鏈�', '4鏈�', '5鏈�', '6鏈�', '7鏈�', '8鏈�', '9鏈�', '10鏈�', '11鏈�', '12鏈�']
+          data: ['1鏈�', '2鏈�', '3鏈�', '4鏈�', '5鏈�', '6鏈�', '7鏈�', '8鏈�', '9鏈�', '10鏈�', '11鏈�', '12鏈�'],
         },
         yAxis: {
-          type: 'value'
+          type: 'value',
         },
         series: []
       }

--
Gitblit v1.9.3