From 7c0327c1b8735c566fb334ad7b87b9ea565ac771 Mon Sep 17 00:00:00 2001 From: ssongliu <73214554+ssongliu@users.noreply.github.com> Date: Mon, 29 May 2023 15:10:40 +0800 Subject: [PATCH] =?UTF-8?q?fix:=20=E4=BF=AE=E5=A4=8D=E6=A6=82=E8=A7=88?= =?UTF-8?q?=E9=A1=B5=E6=95=B0=E6=8D=AE=E5=8A=A0=E8=BD=BD=E5=A4=B1=E8=B4=A5?= =?UTF-8?q?=E7=9A=84=E9=97=AE=E9=A2=98=20(#1178)?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- frontend/src/views/home/index.vue | 1 - frontend/src/views/home/status/index.vue | 1 + 2 files changed, 1 insertion(+), 1 deletion(-) diff --git a/frontend/src/views/home/index.vue b/frontend/src/views/home/index.vue index 243fc9f43..87bf5e0da 100644 --- a/frontend/src/views/home/index.vue +++ b/frontend/src/views/home/index.vue @@ -357,7 +357,6 @@ const onLoadBaseInfo = async (isInit: boolean, range: string) => { statuRef.value.acceptParams(currentInfo.value, baseInfo.value); appRef.value.acceptParams(); if (isInit) { - // window.addEventListener('resize', changeChartSize); timer = setInterval(async () => { onLoadCurrentInfo(); }, 3000); diff --git a/frontend/src/views/home/status/index.vue b/frontend/src/views/home/status/index.vue index 91a059dfe..aaeba4a97 100644 --- a/frontend/src/views/home/status/index.vue +++ b/frontend/src/views/home/status/index.vue @@ -207,6 +207,7 @@ const acceptParams = (current: Dashboard.CurrentInfo, base: Dashboard.BaseInfo): freshChart('cpu', 'CPU', formatNumber(currentInfo.value.cpuUsedPercent)); freshChart('memory', i18n.global.t('monitor.memory'), formatNumber(currentInfo.value.MemoryUsedPercent)); freshChart('load', i18n.global.t('home.load'), formatNumber(currentInfo.value.loadUsagePercent)); + currentInfo.value.diskData = currentInfo.value.diskData || []; nextTick(() => { for (let i = 0; i < currentInfo.value.diskData.length; i++) { let itemPath = currentInfo.value.diskData[i].path;