I have created some new custom controls like here:
This is working great. But I have a requirement, for which I cannot find the solution:
One of my custom control should only allow “Data Input Associations” but no “Flow Connections”. How can I configure this for my new controls?
Hi @symas ,
can you elaborate a bit more about what you want to achieve with the custom control?
It sounds more like you want custom rules to allow connections, like we do in sub-processes for example:
This can be achieved by adding custom rules: diagram-js/RuleProvider.js at develop · bpmn-io/diagram-js · GitHub
When I now draw my new element, then I can choose in the contextpad “Connect using Sequence/MessageFlow or Association”. If I select that, a SequenceFlow is created by default. However, I only want to offer the possibility to create an association here. That means it shouldn’t be possible to select a flow - accordingly I don’t want to prevent this with a rule. With the rule I could prevent a flow from being created via the Global Connector Tool.
Specifically, the question arises: how can I adapt the ContextPad for my new element so that no flows but only association can be selected?