mirror of
				https://github.com/TeaOSLab/EdgeAdmin.git
				synced 2025-11-04 13:10:26 +08:00 
			
		
		
		
	
		
			
				
	
	
		
			23 lines
		
	
	
		
			468 B
		
	
	
	
		
			JavaScript
		
	
	
	
	
	
			
		
		
	
	
			23 lines
		
	
	
		
			468 B
		
	
	
	
		
			JavaScript
		
	
	
	
	
	
Tea.context(function () {
 | 
						|
	this.teaweb = teaweb
 | 
						|
 | 
						|
	this.deleteNode = function (nodeId) {
 | 
						|
		teaweb.confirm("确定要删除这个节点吗?", function () {
 | 
						|
			this.$post("/nodes/delete")
 | 
						|
				.params({
 | 
						|
					nodeId: nodeId
 | 
						|
				})
 | 
						|
				.refresh();
 | 
						|
		})
 | 
						|
	}
 | 
						|
 | 
						|
	this.upNode = function (nodeId) {
 | 
						|
		teaweb.confirm("确定要手动上线此节点吗?", function () {
 | 
						|
			this.$post("/clusters/cluster/node/up")
 | 
						|
				.params({
 | 
						|
					nodeId: nodeId
 | 
						|
				})
 | 
						|
				.refresh()
 | 
						|
		})
 | 
						|
	}
 | 
						|
}) |