[MGNLPRIV-52] Select field inside of multivalue does not properly select first value Created: 15/Mar/18  Updated: 30/Jan/23  Resolved: 30/Jan/23

Status: Closed
Project: Privacy
Component/s: None
Affects Version/s: None
Fix Version/s: None

Type: Bug Priority: Neutral
Reporter: James Spence Assignee: Unassigned
Resolution: Outdated Votes: 0
Labels: y2k
Remaining Estimate: Not Specified
Time Spent: Not Specified
Original Estimate: Not Specified

Issue Links:
causality
duplicate
is duplicated by MGNLPRIV-47 Cookie field inside a multivalue fiel... Closed
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:
Team: AdminX

 Description   

Consider the following field definition:

 

- name: test
  label: Test multivalue
  class: info.magnolia.ui.form.field.definition.MultiValueFieldDefinition
  transformerClass: info.magnolia.ui.form.field.transformer.multi.MultiValueSubChildrenNodeTransformer
  required: true
  field:
    name: selectTestform.field.definition.TextFieldDefinition
    class: info.magnolia.ui.form.field.definition.SelectFieldDefinition
    label: Select test
    options:
      test:
        label: Test
      test2:
        label: Test2

With this field definition, when adding items to the multivalue list, the first value in the select field is selected. However, upon saving, the value is not actually properly saved - it gets discarded.



 Comments   
Comment by Jonathan Ayala [ 07/Mar/19 ]

A workaround could be using

transformerClass: info.magnolia.ui.form.field.transformer.multi.DelegatingMultiValueFieldTransformer

This way values are correctly stored, however they change their JCR structure.

Comment by Matt Rajkovic [ 30/Jan/23 ]

Very old issue. Closing.

Generated at Mon Feb 12 10:31:11 CET 2024 using Jira 9.4.2#940002-sha1:46d1a51de284217efdcb32434eab47a99af2938b.