amend
This commit is contained in:
@ -54,14 +54,18 @@ export default function ContextPadProvider(
|
|||||||
window.bpmnInstances.bpmnElement
|
window.bpmnInstances.bpmnElement
|
||||||
);
|
);
|
||||||
|
|
||||||
// TODO:设置开始节点默认名称
|
// TODO:设置通过左面板创建的开始、结束节点的默认名称
|
||||||
const bpmnElement = window.bpmnInstances.bpmnElement;
|
const bpmnElement = window.bpmnInstances.bpmnElement;
|
||||||
|
console.log(bpmnElement.type);
|
||||||
if (bpmnElement.type === "bpmn:StartEvent") {
|
if (bpmnElement.type === "bpmn:StartEvent") {
|
||||||
window.bpmnInstances.modeling.updateProperties(bpmnElement, {
|
window.bpmnInstances.modeling.updateProperties(bpmnElement, {
|
||||||
name: "开始",
|
name: "开始",
|
||||||
});
|
});
|
||||||
|
} else if (bpmnElement.type === "bpmn:EndEvent") {
|
||||||
|
window.bpmnInstances.modeling.updateProperties(bpmnElement, {
|
||||||
|
name: "结束",
|
||||||
|
});
|
||||||
}
|
}
|
||||||
|
|
||||||
var context = event.context,
|
var context = event.context,
|
||||||
shape = context.shape;
|
shape = context.shape;
|
||||||
|
|
||||||
|
Reference in New Issue
Block a user