From 127347fab0ca8be5b9529d072b0cd30803cc449c Mon Sep 17 00:00:00 2001 From: g7hoo Date: Sun, 9 Oct 2022 16:57:02 +0800 Subject: [PATCH] =?UTF-8?q?update=20=E4=BF=AE=E6=94=B9=E5=BD=93=E5=89=8D?= =?UTF-8?q?=E6=A3=80=E6=B5=8B=E6=95=B0=E6=8D=AE=E7=9A=84=E5=9B=BE=E4=BE=8B?= =?UTF-8?q?=E9=85=8D=E7=BD=AE?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../monitoring/qualityInspectionCurrent.vue | 22 +++++++++++++++---- 1 file changed, 18 insertions(+), 4 deletions(-) diff --git a/src/views/modules/monitoring/qualityInspectionCurrent.vue b/src/views/modules/monitoring/qualityInspectionCurrent.vue index 4ac4f16..877bad0 100644 --- a/src/views/modules/monitoring/qualityInspectionCurrent.vue +++ b/src/views/modules/monitoring/qualityInspectionCurrent.vue @@ -105,17 +105,31 @@ const FakeChart = { calcMaxHeight, chart: null, defaultOpts: { + grid: { + left: '5%', + right: '12%', + top: '20%', + bottom: '10%' + }, title: { text: i18n.t('inspect.typeCount') }, tooltip: {}, legend: { orient: 'vertical', + type: 'scroll', top: 10, - right: 20, - data: [ - /** dynamic */ - ] + right: 0, + width: '12%', + /** 修复文本太长时显示问题 */ + formatter: function(name) { + return echarts.format.truncateText(name, 120, '14px Microsoft Yahei', '...') + }, + tooltip: { + show: true + }, + /** end */ + data: [] }, xAxis: { data: [