Commit 24cfd2e7e5d9982eda688eaab4d64540d3ef1f9b

Authored by chenparty
Committed by GitHub
1 parent 715c7d27

修正首次打开页面报请求失败的提示

mediaServerChoose获取到之前,执行updateData, 会导致getAllSession函数获取不到mediaServerChoose。
web_src/src/components/control.vue
... ... @@ -137,15 +137,13 @@ export default {
137 137 mounted() {
138 138  
139 139 this.initTable();
140   - this.updateData();
141 140 this.chartInterval = setInterval(this.updateData, 3000);
142 141 this.mediaServer.getOnlineMediaServerList((data)=>{
143 142 this.mediaServerList = data.data;
144 143 if (this.mediaServerList && this.mediaServerList.length > 0) {
145 144 this.mediaServerChoose = this.mediaServerList[0].id
146 145 this.loadCount = this.mediaServerList[0].count;
147   - this.getThreadsLoad();
148   - this.getAllSession();
  146 + this.updateData();
149 147 }
150 148 })
151 149 },
... ...