mirror of
https://github.com/jumpserver/lina.git
synced 2025-08-29 03:41:35 +00:00
[Update] 添加更新节点资产硬件信息执行逻辑
This commit is contained in:
parent
a2b88067c3
commit
b29a61b792
@ -148,7 +148,19 @@ export default {
|
||||
|
||||
},
|
||||
updateNodeAssetHardwareInfo: function() {
|
||||
|
||||
this.hideRMenu()
|
||||
const currentNode = this.zTree.getSelectedNodes()[0]
|
||||
if (!currentNode) {
|
||||
return
|
||||
}
|
||||
this.$axios.post(
|
||||
`/api/v1/assets/nodes/${currentNode.meta.node.id}/tasks/`,
|
||||
{ 'action': 'refresh' }
|
||||
).then((res) => {
|
||||
window.open(`/core/ops/celery/task/${res.task}/log/`, '_blank', 'toolbar=yes, width=900, height=600')
|
||||
}).catch(error => {
|
||||
this.$message.error(this.$t('common.updateErrorMsg' + ' ' + error))
|
||||
})
|
||||
},
|
||||
testNodeAssetConnectivity: function() {
|
||||
|
||||
|
Loading…
Reference in New Issue
Block a user