设备监控页面添加定时器请求接口

This commit is contained in:
wu
2022-08-22 15:37:49 +08:00
parent 64388ae7b5
commit 20cd6e0f3a

View File

@@ -11,10 +11,7 @@
>前置服务 {{ item.server_name }} ({{ item.url }}:{{ item.port }} )
<el-tag
:color="serveStatus[item.status].backgroundColor"
:style="{
color: serveStatus[item.status].textColor,
borderColor: serveStatus[item.status].borderColor,
}"
:style="{color:serveStatus[item.status].textColor,borderColor:serveStatus[item.status].borderColor}"
>
{{ serveStatus[item.status].name }}
</el-tag>
@@ -211,14 +208,15 @@ export default {
type: 'error'
})
this.$set(this.serverData[index], 'status', 'offline')
// this.$delete(this.serverData, index);
})
})
}
},
mounted () {
this.getServe()
setInterval(()=>{
this.getServe()
}, 30000)
}
}
</script>