From 39fd6f3e7a4ba99ecbe1a75884801bac7116584d Mon Sep 17 00:00:00 2001 From: chenjinsong <523037378@qq.com> Date: Tue, 6 Sep 2022 11:37:56 +0800 Subject: [PATCH] =?UTF-8?q?fix:=20=E4=BF=AE=E5=A4=8D=E4=B8=80=E5=BC=80?= =?UTF-8?q?=E5=A7=8B=E6=B2=A1=E6=95=B0=E6=8D=AE=EF=BC=8C=E6=9B=B4=E6=94=B9?= =?UTF-8?q?=E6=9D=A1=E4=BB=B6=E5=90=8E=E6=9C=89=E6=95=B0=E6=8D=AE=E4=B9=9F?= =?UTF-8?q?=E5=88=B7=E4=B8=8D=E5=87=BA=E6=9D=A5=E7=9A=84=E9=97=AE=E9=A2=98?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/views/charts2/charts/npm/NpmAppCategoryScore.vue | 3 ++- src/views/charts2/charts/npm/NpmNetworkQuantity.vue | 5 +++-- 2 files changed, 5 insertions(+), 3 deletions(-) diff --git a/src/views/charts2/charts/npm/NpmAppCategoryScore.vue b/src/views/charts2/charts/npm/NpmAppCategoryScore.vue index 2fa139b1..049e2349 100644 --- a/src/views/charts2/charts/npm/NpmAppCategoryScore.vue +++ b/src/views/charts2/charts/npm/NpmAppCategoryScore.vue @@ -136,7 +136,6 @@ export default { mixins: [chartMixin], watch: { timeFilter: { - deep: true, handler (n) { this.init() } @@ -206,6 +205,8 @@ export default { }) this.tableData = tableData }) + } else { + this.tableData = [] } }).finally(() => { this.toggleLoading(false) diff --git a/src/views/charts2/charts/npm/NpmNetworkQuantity.vue b/src/views/charts2/charts/npm/NpmNetworkQuantity.vue index 42220012..f4cad293 100644 --- a/src/views/charts2/charts/npm/NpmNetworkQuantity.vue +++ b/src/views/charts2/charts/npm/NpmNetworkQuantity.vue @@ -99,12 +99,14 @@ export default { const packetPercent = get(api.npm.overview.packetRetransPercent, params) this.toggleLoading(true) Promise.all([tcp, http, ssl, tcpPercent, packetPercent]).then(res => { + this.npmNetworkCycleData = [] res.forEach(t => { if (t.code === 200) { this.npmNetworkCycleData.push(t.data.result) } }) - }).finally(() => { + this.npmNetworkLastCycleQuery() + }).catch(e => { this.toggleLoading(false) }) } @@ -266,7 +268,6 @@ export default { this.chartData = _.cloneDeep(this.chart) } this.npmNetworkCycleQuery() - this.npmNetworkLastCycleQuery() } }