!24 feat(bpm): 新增发起销号流程功能,流程code为dq_delete_01
* feat(bpm): 新增发起销号流程功能,流程code为dq_delete_01
This commit is contained in:
@@ -261,6 +261,12 @@
|
||||
onClick: handleProcess.bind(null, record),
|
||||
});
|
||||
}
|
||||
if (record.bpmStatus && record.bpmStatus !== '1') {
|
||||
actions.push({
|
||||
label: '发起销号流程',
|
||||
onClick: handleDeleteProcess.bind(null, record),
|
||||
});
|
||||
}
|
||||
return actions;
|
||||
}
|
||||
/**
|
||||
@@ -298,12 +304,17 @@
|
||||
const FLOW_CODE = 'inspect_flow_create_01';
|
||||
const FLOW_NAME = '整改任务';
|
||||
const BUSINESS_TABLE_NAME = 'dq_inspect_task';
|
||||
const FORM_URL = 'dqinspecttask/components/DqInspectTaskBPMForm?showProcessHandle=0&showFeedbackInfo=1';
|
||||
const FORM_URL = 'dq/inspectTask/components/DqInspectTaskBPMForm?showProcessHandle=1&showFeedbackInfo=1';
|
||||
const DELETE_FLOW_CODE = 'dq_delete_01';
|
||||
const DELETE_FLOW_NAME = '销号';
|
||||
const DELETE_FORM_URL = 'dq/inspectTask/components/DqInspectTaskBPMForm?showProcessHandle=1&showFeedbackInfo=1';
|
||||
const currentScheduleFlowCode = ref('');
|
||||
|
||||
/**
|
||||
* 发起流程
|
||||
*/
|
||||
function handleProcess(record) {
|
||||
currentScheduleFlowCode.value = FLOW_CODE;
|
||||
flowScheduleModalRef.value?.open({
|
||||
title: '发起整改任务流程',
|
||||
payload: { record },
|
||||
@@ -315,11 +326,31 @@
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* 发起销号流程
|
||||
*/
|
||||
function handleDeleteProcess(record) {
|
||||
currentScheduleFlowCode.value = DELETE_FLOW_CODE;
|
||||
flowScheduleModalRef.value?.open({
|
||||
title: '发起销号流程',
|
||||
payload: { record },
|
||||
deptOptions: getDeptOptions(record),
|
||||
showSuoleaderFields: true,
|
||||
isNeedAppro: record.isNeedAppro,
|
||||
supDeptleaderid: record.supDeptleaderid,
|
||||
supDeptleaderName: record.supDeptleaderid_dictText,
|
||||
});
|
||||
}
|
||||
|
||||
/**
|
||||
* 流程调度确认
|
||||
*/
|
||||
async function handleFlowScheduleConfirm({ payload, options }) {
|
||||
const record = payload?.record || {};
|
||||
const isDeleteFlow = currentScheduleFlowCode.value === DELETE_FLOW_CODE;
|
||||
const flowCode = isDeleteFlow ? DELETE_FLOW_CODE : FLOW_CODE;
|
||||
const flowName = isDeleteFlow ? DELETE_FLOW_NAME : FLOW_NAME;
|
||||
const formUrl = isDeleteFlow ? DELETE_FORM_URL : FORM_URL;
|
||||
|
||||
const params = {
|
||||
intervalType: options.intervalType,
|
||||
@@ -327,9 +358,9 @@
|
||||
taskTask: {
|
||||
triggerType: options.triggerType,
|
||||
startTime: options.intervalStartTime,
|
||||
flowCode: FLOW_CODE,
|
||||
formUrl: FORM_URL,
|
||||
flowName: FLOW_NAME,
|
||||
flowCode,
|
||||
formUrl,
|
||||
flowName,
|
||||
jsonData: { ...record },
|
||||
businessTablename: BUSINESS_TABLE_NAME,
|
||||
businessId: record.id,
|
||||
|
||||
Reference in New Issue
Block a user