From bf6ecba04524ae5bbceddadc74c6514d69981161 Mon Sep 17 00:00:00 2001 From: lb Date: Tue, 22 Nov 2022 13:21:44 +0800 Subject: [PATCH] =?UTF-8?q?update=20=E8=B4=A8=E9=87=8F=E7=AE=A1=E7=90=86?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../components/TechyAnalysisHeader.vue | 17 ++++++++++------- .../components/charts/TechyBar.vue | 19 ++++++++++++++++--- 2 files changed, 26 insertions(+), 10 deletions(-) diff --git a/src/views/QualityManager/components/TechyAnalysisHeader.vue b/src/views/QualityManager/components/TechyAnalysisHeader.vue index 0ca14ec..6232a5c 100644 --- a/src/views/QualityManager/components/TechyAnalysisHeader.vue +++ b/src/views/QualityManager/components/TechyAnalysisHeader.vue @@ -2,12 +2,12 @@
diff --git a/src/views/QualityManager/components/charts/TechyBar.vue b/src/views/QualityManager/components/charts/TechyBar.vue index d0ca352..4255c99 100644 --- a/src/views/QualityManager/components/charts/TechyBar.vue +++ b/src/views/QualityManager/components/charts/TechyBar.vue @@ -142,7 +142,7 @@ export default { show: true, position: 'top', color: '#fff8', - fontSize: 8, + fontSize: 10, offset: [0, 6] } } @@ -174,9 +174,22 @@ export default { }, axisLabel: { color: '#fff8', - fontSize: 10 + fontSize: 12 }, - data: ['脏污', '破片', '崩边', '崩孔', '划擦伤', '其他'] + data: ['脏污', '破片', '崩边', '崩孔', '划擦伤', '其他'], + axisPointer: { + show: true, + type: 'shadow', + label: { + show: true, + formatter: params => { + let info_arr = params.seriesData.filter(item => item.seriesType === 'bar') + let v = [`<${info_arr[0].name}>详细数据: \n`] + info_arr.map(item => { v.push(`${item.seriesName}: ${item.data}`) }) + return v.join('\n') + } + } + } }, yAxis: { type: 'value',