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

Support binding of enumDatasource

XMLWordPrintable

    • Icon: Improvement Improvement
    • Resolution: Unresolved
    • Icon: Neutral Neutral
    • None
    • 6.2.13
    • None
    • None

      Actually, if an enumDatasource is used as datasource of a combobox field, the error message: "Linking to enums is not supported" is thrown because the method getDefaultConverter is unimplemented.

      For every particular enum that is used as the source of a Datasource, a subtype of EnumSelectFieldSupport has to be implemented providing a #defaultConverter() (so the enum values are converted into a presentation String)

      It would be also useful to implement an interface translatableEnum with one method String getTranslationKey() which could be implemented/extended by EnumSelectFieldSupport to get the keys for the translations of enum values.

      On some IDEs like IntelliJ, it is needed to include the annotation formatter:off - formatter_on between the implementationClass at the module descriptor regarding significant white spaces, it could be useful to include some java code control like trim for avoiding this issue

        Acceptance criteria

              Unassigned Unassigned
              ccantalapiedra Carlos Cantalapiedra
              Votes:
              3 Vote for this issue
              Watchers:
              5 Start watching this issue

                Created:
                Updated:

                  Task DoD