提交 c9e5476b authored 作者: kxjia's avatar kxjia

修改工作流多实例问题

上级 c90615cf
......@@ -63,7 +63,8 @@ const editableColumns = [
]
const defaultProperties = [
{ name: 'isApprove', value: 'false' }
{ name: 'isApprove', value: 'false' },
{ name: 'isEdit', value: 'false' },
]
onMounted(() => {
......
......@@ -6,7 +6,6 @@
@sendWorkFlow="handleDefinitionSend"
@endWorkFlow="handleDefinitionEnd"
@open-multi-form="handleOpenMultiForm"
@open-flow-form="handleOpenFlowForm"
:todo-list="todoList"
/>
<WorkFlowFormDrawer
......@@ -152,7 +151,8 @@
if (!data.procInsId) {
await handleDefinitionStart(data)
}
await setCurrentNodeById(data);
dataId.value = data.id;
deployId.value = currentNode.value.deployId || '';
......@@ -210,7 +210,9 @@
}
};
const handleDrawerClose = () => { drawerVisible.value = false; };
const handleDrawerClose = () => {
drawerVisible.value = false;
};
const handleMultiFormDataUpdate = (_data: any) => {
const currentFormComponent = getCurrentFormComponent();
if (currentFormComponent?.handleRefresh) {
......@@ -245,6 +247,7 @@
}
async function handleOpenMultiForm(data: any) {
deployId.value = currentNode.value.deployId || '';
procInsId.value = data.procInsId || '';
drawerVisible.value = true;
......@@ -267,9 +270,7 @@
nextTick(() => {
if(resData.formUrl) {
mainFormUrl.value = resData.formUrl
alert(mainFormUrl.value)
mainFormListUrl.value = resData.formListurl || ''
alert(mainFormListUrl.value)
} else {
mainFormUrl.value = ""
refInnerForm.value.iniData(resData)
......@@ -288,13 +289,22 @@
startTime: undefined,
});
const setCurrentNodeById = async (nodeId: string) =>{
const nodes = workflowNodes.value;
const index = nodes.findIndex(node => node.id === nodeId);
if (index !== -1) {
currentMultiFormIndex.value = index;
currentNode.value = nodes[index];
}
}
onMounted(async () => {
await nextTick();
try {
const nodes = await getNodesByTableName(formTableName);
todoaLLList.value = await todoList(queryParams);
workflowNodes.value = nodes;
if (workflowNodes.value?.length > 0) {
workflowNodes.value.forEach(node => {
......
......@@ -35,7 +35,7 @@
import BaosongAllocDrawer from '../form/BaosongAllocDrawer.vue';
const [registerModal, { openModal }] = useModal();
const refAllocDrawer = ref<InstanceType<typeof BaosongAllocDrawer>>();
const refAllocDrawer = ref();
const { tableContext } = useListPage({
tableProps: {
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论