From e2d67072497951a7433f597e93e2bc8c0fe6570e Mon Sep 17 00:00:00 2001 From: =?UTF-8?q?=E5=88=98=E6=B4=AA=E6=B4=AA?= <2498601771@qq.com> Date: Thu, 24 Nov 2022 11:03:53 +0800 Subject: [PATCH] =?UTF-8?q?fix:=20NpmNetworkQuantity=E6=A8=A1=E5=9D=97?= =?UTF-8?q?=E5=8E=BB=E9=99=A4=E6=A8=A1=E6=8B=9F=E6=95=B0=E6=8D=AE?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/views/charts2/charts/npm/NpmNetworkQuantity.vue | 9 ++------- 1 file changed, 2 insertions(+), 7 deletions(-) diff --git a/src/views/charts2/charts/npm/NpmNetworkQuantity.vue b/src/views/charts2/charts/npm/NpmNetworkQuantity.vue index 63ff9c9e..1fb696cb 100644 --- a/src/views/charts2/charts/npm/NpmNetworkQuantity.vue +++ b/src/views/charts2/charts/npm/NpmNetworkQuantity.vue @@ -126,13 +126,8 @@ export default { const packetPercent = get(api.npm.overview.packetRetransPercent, params) this.toggleLoading(true) Promise.all([tcp, http, ssl, tcpPercent, packetPercent]).then(res => { - // todo 模拟数据,记得删 - res[0] = { - code: 50001, - msg: 'jhgfdfghjklkjhg' - } this.npmNetworkCycleData = [] - res.forEach((t, index) => { + res.forEach(t => { if (t.code === 200) { this.npmNetworkCycleData.push(t.data.result) } else { @@ -145,7 +140,7 @@ export default { // 此时e为数组 if (e instanceof Array) { this.npmNetworkCycleData = [] - e.forEach((t) => { + e.forEach(t => { this.npmNetworkCycleData.push(t) }) this.npmNetworkLastCycleQuery()