diff --git a/src/views/auditPages/taskManagement.vue b/src/views/auditPages/taskManagement.vue index 82573ca..13e2e2c 100644 --- a/src/views/auditPages/taskManagement.vue +++ b/src/views/auditPages/taskManagement.vue @@ -99,10 +99,21 @@ 查看 - 审核 - 关闭 @@ -167,6 +178,34 @@ export default { this.getList(); }, methods: { + // 关闭 + handleClose(row) { + this.$confirm("此操作将关闭任务, 是否继续?", "提示", { + confirmButtonText: "确定", + cancelButtonText: "取消", + type: "warning", + }) + .then(() => { + assetTaskclose({ taskId: row.id, taskName: row.taskName }).then( + (res) => { + if (res.code == 200) { + this.$message({ + type: "success", + message: "关闭成功!", + }); + this.getList(); + } + } + ); + }) + .catch(() => { + this.$message({ + type: "info", + message: "已取消关闭", + }); + }); + }, + // 修改table背景色 tableRowClassName({ row, rowIndex }) { if (rowIndex % 2 !== 0) {