Files
EdgeAdmin/web/views/@default/clusters/cluster/nodes.js
2021-07-31 22:23:07 +08:00

24 lines
518 B
JavaScript

Tea.context(function () {
this.teaweb = teaweb
this.deleteNode = function (nodeId) {
teaweb.confirm("确定要从当前集群中删除这个节点吗?", function () {
this.$post("/nodes/delete")
.params({
clusterId: this.clusterId,
nodeId: nodeId
})
.refresh();
})
}
this.upNode = function (nodeId) {
teaweb.confirm("确定要手动上线此节点吗?", function () {
this.$post("/clusters/cluster/node/up")
.params({
nodeId: nodeId
})
.refresh()
})
}
})