前置管理分配终端

This commit is contained in:
sjl
2026-01-29 13:44:12 +08:00
parent 7188e3e681
commit 8d9ccf97a7
4 changed files with 97 additions and 12 deletions

View File

@@ -209,7 +209,8 @@ import {
updateNode,
nodeDeviceTree,
updateDeviceProcess,
askRestartProcess
askRestartProcess,
allotTerminal
} from '@/api/device-boot/Business'
import TableStore from '@/utils/tableStore'
import Table from '@/components/table/index.vue'
@@ -384,7 +385,32 @@ const tableStore = new TableStore({
tableStore.index()
})
}
}
},
{
name: 'edit',
title: '分配终端',
type: 'primary',
icon: 'InfoFilled',
render: 'confirmButton',
popconfirm: {
confirmButtonText: '确认',
cancelButtonText: '取消',
confirmButtonType: 'primary',
title: '确定分配终端吗?'
},
click: row => {
if (!hasDevices.value) {
ElMessage.warning('此前置机下无设备,无法分配终端!');
return;
}
allotTerminal({
nodeId: row.id
}).then(res => {
ElMessage.success(res.message)
tableStore.index()
})
}
},
]
}
],