保存时检查用户任务节点名称是否填写

This commit is contained in:
cxc
2023-01-05 16:32:04 +08:00
parent 49094a5460
commit 8d3acf0839
7 changed files with 161 additions and 61 deletions

View File

@ -10,6 +10,7 @@
'connection.added',
'connection.removed',
'connection.changed',
'create.end',
]"
@element-click="elementClick"
@init-finished="initModeler"
@ -80,7 +81,18 @@ function initModeler(modelerArgv) {
}, 10);
}
function handlerEvent(eventName) {
console.log(eventName);
if (eventName === "connection-added") {
// 设置结束节点的默认名称
nextTick(() => {
if (window?.bpmnInstances?.bpmnElement.type === "bpmn:EndEvent") {
window.bpmnInstances.modeling.updateProperties(
window.bpmnInstances.bpmnElement,
{ name: "结束" }
);
}
});
goToFormSelect();
}
}