yxk-20260526-党委会查询督办流程:写一个通用的删除流程方法

This commit is contained in:
ye1023
2026-05-26 15:40:11 +08:00
parent 60f0c92fca
commit 5f75a6dc85
4 changed files with 97 additions and 59 deletions
+5 -14
View File
@@ -83,7 +83,6 @@
updateLaunchType,
saveOrUpdateDict,
withDrawXiSpeak,
deleteSingleProcess,
getRootListWithDept,
bgXiSpeakFeedbackList,
} from './BgXiSpeak.api';
@@ -137,8 +136,11 @@
},
});
const [registerTable, { reload, collapseAll, updateTableDataRecord, findTableDataRecord, getDataSource, setTableData }, { rowSelection, selectedRowKeys }] =
tableContext;
const [
registerTable,
{ reload, collapseAll, updateTableDataRecord, findTableDataRecord, getDataSource, setTableData },
{ rowSelection, selectedRowKeys },
] = tableContext;
const mainId = computed(() => (unref(selectedRowKeys).length > 0 ? unref(selectedRowKeys)[0] : ''));
provide('mainId', mainId);
@@ -593,20 +595,9 @@
title: '流程列表',
businessId: record.id,
columns: '',
onDeleteProcess: handleDeleteProcess,
});
}
async function handleDeleteProcess(processRecord, reload) {
const res = await deleteSingleProcess({ processInstId: processRecord.processInstId });
if (res.success) {
createMessage.success(res.message || '删除流程成功');
await reload();
} else {
createMessage.error(res.message || '删除流程失败');
}
}
async function handleFlowScheduleConfirm({ payload, options }) {
const record = payload?.record || {};
const flowCode = payload?.flowCode || FLOW_CODE;