]
Michael Anstis updated DROOLS-3249:
-----------------------------------
Tester: Jozef Marko
Labels: drools-tools (was: )
[DMN Designer] Add support for optional typeRefs
------------------------------------------------
Key: DROOLS-3249
URL:
https://issues.jboss.org/browse/DROOLS-3249
Project: Drools
Issue Type: Bug
Components: DMN Editor
Affects Versions: 7.14.0.Final
Reporter: Michael Anstis
Assignee: Daniel José dos Santos
Priority: Critical
Labels: drools-tools
At the moment {{TypeRef}} is a mandatory field within the editor.
This is a hard limitation of use of the Properties Panel bean-binding (it cannot bind to
{{null}} values). However the DMN Specification states that {{TypeRef}} are optional (and
we are working around by changing the _default_ to {{Any}} - see
[
DROOLS-3248|https://issues.jboss.org/browse/DROOLS-3248]).
We need to change the UI and marshaller to be able to support _optional_ {{TypeRef}}.
This would (probably) require adding a _magic_ value to {{BuiltInType}} representing a
"null" selection. It would need to:
- Appear at the top of the "Data Type selector" widget (with label
"<None>" or similar)
- Be the _selected_ option when the {{TypeRef}} is the new _magic_ value (this should
happen automatically, but worth checking!)
- The marshaller should set the {{TypeRef}} to the _magic_ {{BuiltInType}} if the DMN
model (coming from XML->{{kie-dmn-model}}->workbench model) has a {{null}}
{{TypeRef}} - the _magic_ value is only to be used _client-side_.
- The marshaller should set the {{TypeRef}} to {{null}} when converting from the
workbench model to {{kie-dmn-model}} and the workbench model {{TypeRef}} is the _magic_
value - again, the _magic_ value is only to be used _client-side_.
- Check that creating new data-types does not show the _magic_ value (it uses a different
widget, but population of the widget probably iterates all {{BuiltInType}}.
[~tari_manga] [~karreiro] seem reasonable to you?