From b35ae89a354d29643af99cc150812241b940352d Mon Sep 17 00:00:00 2001 From: ZZJ <10913410+zzj2100@user.noreply.gitee.com> Date: 星期五, 15 七月 2022 14:44:46 +0800 Subject: [PATCH] bugxiufu --- src/views/hashrate/HashManage/index.vue | 15 ++++++++++++--- 1 files changed, 12 insertions(+), 3 deletions(-) diff --git a/src/views/hashrate/HashManage/index.vue b/src/views/hashrate/HashManage/index.vue index 37d4ba7..1a220da 100644 --- a/src/views/hashrate/HashManage/index.vue +++ b/src/views/hashrate/HashManage/index.vue @@ -77,6 +77,7 @@ :list="deviceList" @chooseCluster="chooseCluster" @chooseDevice="chooseDevice" + @refreshCluster="chooseCluster(ClusterId)" @back="back" :listType="listType" ></ClusterList> @@ -88,7 +89,6 @@ import ClusterList from "./components/ClusterList"; import { userStatisticRunInfo, - userSysInfo, userStatisticRun, clusterStatisticRunInfo, clusterSysInfo, @@ -102,6 +102,8 @@ ClusterList, }, created() { + sessionStorage.removeItem("devId"); + sessionStorage.removeItem("clusterId"); this.getUserInfo(); this.getUserDevice(); }, @@ -120,6 +122,7 @@ }, deviceList: [], listType: "cluster", + ClusterId: "", }; }, methods: { @@ -160,7 +163,9 @@ res1.data.stackRunningCount, }; } - const res2 = await userSysInfo(); + const res2 = await clusterSysInfo({ + clusterId: "", + }); if (res2 && res2.success) { this.systemInfo = { cpu: parseInt(res2.data.cpu.usedPercent), @@ -215,7 +220,10 @@ res1.data.stackRunningCount, }; } - const res2 = await clusterSysInfo({ clusterId: id }); + const res2 = await clusterSysInfo( + //id + { clusterId: "" } + ); if (res2 && res2.success) { this.systemInfo = { cpu: parseInt(res2.data.cpu.usedPercent), @@ -283,6 +291,7 @@ chooseCluster(id) { this.getClusterInfo(id); this.getClusterDevice(id); + this.ClusterId = id; }, back() { this.getUserInfo(); -- Gitblit v1.8.0