Uploaded image for project: 'Magnolia UI'
  1. Magnolia UI
  2. MGNLUI-3815

i18n & MultiValueFieldFactory

XMLWordPrintable

    • Icon: Bug Bug
    • Resolution: Won't Fix
    • Icon: Neutral Neutral
    • None
    • 5.4.5
    • forms
    • None

      If you don't set a label property on the nested field, info.magnolia.ui.form.field.definition.FieldDefinitionKeyGenerator#keysFor fails with NPE since the name of the field is not set. To reproduce:

      1. /tours/dialogs/components/tourTypeTeaserRow.yaml Remove the label property of the field
      2. Open tourTypeTeaserRow dialog on the home page.
        Caused by: java.lang.NullPointerException
        	at info.magnolia.ui.form.field.definition.FieldDefinitionKeyGenerator.keysFor(FieldDefinitionKeyGenerator.java:64)
        	at info.magnolia.ui.form.field.definition.FieldDefinitionKeyGenerator.keysFor(FieldDefinitionKeyGenerator.java:55)
        
      1. info.magnolia.ui.form.field.definition.MultiValueFieldDefinition#getButtonSelectAddLabel/getButtonSelectRemoveLabel should be annotated with @I18nText so we can use auto generated keys.
      2. Then the translation in info.magnolia.ui.form.field.factory.MultiValueFieldFactory#createFieldComponent should go away.

        Acceptance criteria

              Unassigned Unassigned
              rkovarik Roman Kovařík
              Votes:
              0 Vote for this issue
              Watchers:
              2 Start watching this issue

                Created:
                Updated:
                Resolved:

                  Bug DoR
                  Task DoD