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

Reconsider JCR-specific code in LinkFieldFactory's choose-dialog callback

XMLWordPrintable

    • Icon: Improvement Improvement
    • Resolution: Fixed
    • Icon: Major Major
    • 5.4.4
    • 5.4.3
    • forms
    • Basel 25
    • 5

      LinkFieldFactory$ChooseDialogCallback#onItemChosen is fishy at best. In particular, LinkFieldDefinition's targetPropertyToPopulate property is unclear, undocumented, most likely unused and should be deprecated. It strongly looks like legacy code pre-transformers and pre-identifierToPathConverter—which I'd expect to be used in that callback method instead.

      At the moment, plain LinkFieldDefinition cannot be used with resources app in 5.4, because of this.

      As a workaround, one may use a custom LinkFieldFactory for resources app, as shown at https://git.magnolia-cms.com/projects/modules/repos/resources/commits/1e662634b1243f44242d9f321ca9a75a1354e30b

        Acceptance criteria

              cmeier Christoph Meier
              zdenekskodik Zdenek Skodik
              Votes:
              0 Vote for this issue
              Watchers:
              4 Start watching this issue

                Created:
                Updated:
                Resolved:

                  Task DoD

                    Estimated:
                    Original Estimate - Not Specified
                    Not Specified
                    Remaining:
                    Remaining Estimate - 0d
                    0d
                    Logged:
                    Time Spent - 1d 1h
                    1d 1h