diff --git a/templates/front-project/src/views/machineViews/MachineList.vue b/templates/front-project/src/views/machineViews/MachineList.vue index ffd0605a83a4c80ab9d5a0413f5c955ba745b7ef..3b5dbf142e7e333ef9d2ca775cbf47e30f8c0e78 100644 --- a/templates/front-project/src/views/machineViews/MachineList.vue +++ b/templates/front-project/src/views/machineViews/MachineList.vue @@ -138,6 +138,34 @@ export default { }); }, + reset() { + this.machineData = { + machine_name: '', + cpu_module_name: '', + arch_name: '', + BMC_IP: '', + BMC_user_name: '', + BMC_password: '', + } + this.getData() + }, + + + //删除数据 + del(row) { + this.$confirm(`确认删除此行数据吗?`, '提示', { + confirmButtonText: '确定', + cancelButtonText: '取消', + type: 'warning' + }).then(() => { + machine_list('delete', {id: row.id}).then(response => { + if (response.data.code === 200) { + ElMessage({message: response.data.message, type: 'success'}) + this.getData() + } + }) + }) + }, } } ;