[MGNLDATA-244] Improve handling of IdentifierToPathConverter for DataSelectFieldFactory. Created: 23/Jan/14  Updated: 03/Feb/14  Resolved: 31/Jan/14

Status: Closed
Project: Magnolia Data Module (closed)
Component/s: None
Affects Version/s: 2.2.1
Fix Version/s: 2.2.2

Type: Bug Priority: Major
Reporter: Eric Hechinger Assignee: Eric Hechinger
Resolution: Fixed Votes: 0
Labels: None
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Attachments: XML File config.modules.data.config.options.xml     XML File config.modules.data.dialogs.company.form.tabs.addressTab.fields.select.xml     XML File config.modules.ui-admincentral.config.appLauncherLayout.groups.data.apps.companyApp.xml    
Template:
Acceptance criteria:
Empty
Date of First Response:

 Description   

Case not yet handled:
A converter is defined (JCR store the option identifier, and display the value) together with a default value (This default value is displayed the first time the dialog is displayed).

In this case the default value (Option name) has to be converted to an identifier in createDefaultValue() in order to be supported by the converter.

How to reproduce:

  • Create a new DataSelectField field (by configuration)
  • This dataSelectField has to
    • define a IdentifierToPathConvertor (the value of the selected option is the Node identifier of the option)
    • point to remote options
    • one of the remote option has to define a default value.

The first time the dialog containing this field is displayed, the default value configured has to be selected. If no change done, after saving the dialog, the Identifier of the default option has to be saved.

Provided config file:

  • config.modules.data.config.options.xml: remote options definition (fr is set as default)
  • config.modules.data.dialogs.company.form.tabs.addressTab.fields.select.xml : select field definition set to a company dialog
  • config.modules.ui-admincentral.config.appLauncherLayout.groups.data.apps.companyApp.xml : activate the company app.


 Comments   
Comment by Daniel Lipp [ 31/Jan/14 ]

DataSelectFieldFactory#createDefaultValue ignores exception - we have at least to log a warning.

Generated at Mon Feb 12 05:12:45 CET 2024 using Jira 9.4.2#940002-sha1:46d1a51de284217efdcb32434eab47a99af2938b.