[MGNLUI-6168] Override directive not disabling tabs under new UI config Created: 28/Aug/20 Updated: 28/Sep/20 Resolved: 24/Sep/20 |
|
| Status: | Closed |
| Project: | Magnolia UI |
| Component/s: | app framework |
| Affects Version/s: | 6.2.2 |
| Fix Version/s: | 6.2.4 |
| Type: | Bug | Priority: | Neutral |
| Reporter: | Carlos Cantalapiedra | Assignee: | Oanh Thai Hoang |
| Resolution: | Fixed | Votes: | 0 |
| Labels: | compatibility-module, maintenance, quickwin | ||
| Remaining Estimate: | 0d | ||
| Time Spent: | 0.75d | ||
| Original Estimate: | Not Specified | ||
| Issue Links: |
|
||||
| Template: |
|
||||
| Acceptance criteria: |
Empty
|
||||
| Task DoD: |
[ ]*
Doc/release notes changes? Comment present?
[ ]*
Downstream builds green?
[ ]*
Solution information and context easily available?
[ ]*
Tests
[ ]*
FixVersion filled and not yet released
[ ] 
Architecture Decision Record (ADR)
|
||||
| Bug DoR: |
[ ]*
Steps to reproduce, expected, and actual results filled
[ ]*
Affected version filled
|
||||
| Date of First Response: | |||||
| Epic Link: | UI framework implementation | ||||
| Sprint: | Maintenance 26 | ||||
| Story Points: | 2 | ||||
| Description |
|
Overriding (disabling) a tab using new YAML syntax doesn't work. Steps to reproduce:
Actual result: Expected result: Dev notes:
form:
tabs:
- name: cookie
label: My Cookie tab
fields:
- name: showCookieMessage
class: info.magnolia.ui.form.field.definition.CheckboxFieldDefinition
defaultValue: false
i18n: false
type: Boolean
label: Cookies
buttonLabel: Label button
|
| Comments |
| Comment by Carlos Cantalapiedra [ 21/Sep/20 ] |
|
Workaround provided by pmueller: Patch info.magnolia.ui.form.definition.DefinitionConverter on line 16 with the following lline of code:
tabbedLayoutDefinition.setTabs(oldDefinition.getTabs().stream().filter(t -> t.getFields() != null && !t.getFields().isEmpty()).map(TAB::convert).collect(Collectors.toList()));
|
| Comment by Philip Müller [ 21/Sep/20 ] |
|
It's line 167 |
| Comment by Richard Gange [ 21/Sep/20 ] |
|
Perfect, I will create a PR. |