From 772b47e0a55a5ebc6d987b11fc1aad3d9daa0932 Mon Sep 17 00:00:00 2001 From: mabofu Date: Wed, 17 Jul 2024 13:04:38 +0800 Subject: [PATCH] =?UTF-8?q?fixed=20bug-IADJXQ=EF=BC=9AThe=20cluster=20capa?= =?UTF-8?q?city=20chart=20always=20loading=20when=20no=20osd?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/components/echarts/pie.vue | 2 +- src/views/home/index.vue | 2 +- src/views/monitor-center/cluster-status/index.vue | 2 +- 3 files changed, 3 insertions(+), 3 deletions(-) diff --git a/src/components/echarts/pie.vue b/src/components/echarts/pie.vue index 9be51fd..5c73cf7 100644 --- a/src/components/echarts/pie.vue +++ b/src/components/echarts/pie.vue @@ -83,7 +83,7 @@ const option = computed(() => ({ return template; } }, - data: props.data + data: props.data[0] !== null ? props.data : [] } ] })); diff --git a/src/views/home/index.vue b/src/views/home/index.vue index 1cc9c4c..645f8b3 100644 --- a/src/views/home/index.vue +++ b/src/views/home/index.vue @@ -127,7 +127,7 @@ const fetchData = () => { color: '#5470C6' } }, - ] : []; + ] : [null]; state.nodeData = [ { value: onlineNode || 0, diff --git a/src/views/monitor-center/cluster-status/index.vue b/src/views/monitor-center/cluster-status/index.vue index e30c238..0bcb015 100644 --- a/src/views/monitor-center/cluster-status/index.vue +++ b/src/views/monitor-center/cluster-status/index.vue @@ -177,7 +177,7 @@ const getMonitorList = () => { color: '#5470C6' } }, - ] : []; + ] : [null]; }).catch(() => { state.osdData = []; state.monData = []; -- Gitee