Review main Merged

72645[BUGFIX] Pass default/override values to FormSelectTreeAjaxController

Oli Bartsch CR +2 V +2 Easy +17 −2 updated 12/14/21, 09:33

Commit message

The SelectTree and the CategoryTree use a placeholder
form element with all the information like current value
and then calls the FormSelectTreeAjaxController to
actually build the tree.

When using default / override values for such field,
the information was previously only available on
building the placeholder. Therefore the value was
correctly filled and stored, but not displayed in
corresponding tree.

This is now fixed by passing those values to the
Ajax endpoint, which then adds them to the form
compiler input. This allows the data providers to
properly select the values in the tree.

Review

  • Code review CR +2 Done
    • Oli Bartsch +2
    • Nikita Hovratov +1
    • Benni Mack +1
  • Verified V +2 Done
    • Oli Bartsch +2
    • Nikita Hovratov +1
    • Benni Mack +1
    • core-ci +1 CI

Issues 1

Files 7

Review log 1012

  1. Oli Bartsch uploaded patch set 1 12/13/21, 15:08

  2. core-ci voted on patch set 1 V +1 12/13/21, 15:22 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/21037

  3. Nikita Hovratov commented on patch set 1 V +1 12/13/21, 19:40

    Works as expected.
    If you happen to push another patch, can you squish that extra white space ? :)

    SelectTreeElement.php:175

    Shouldn't this also be useHtmlEntities=false ? (Correct me if I'm wrong).
  4. Oli Bartsch commented on patch set 1 12/13/21, 20:30

    SelectTreeElement.php:175 Reply

    No, this is correct. All values should be htmlspecialchar'd. This is only set to FALSE in the CategoryElement, because those values are added later on using GeneralUtility::implodeAttributes(), with the second parameter (xhtmlSafe) set to TRUE.
  5. Nikita Hovratov commented on patch set 1 CR +1 12/13/21, 21:00

    SelectTreeElement.php:175 Reply

    Ack
  6. Benni Mack voted on patch set 1 V +1 CR +1 12/14/21, 08:31

  7. Benni Mack updated the commit message in patch set 2 12/14/21, 08:32

  8. core-ci voted on patch set 2 V +1 12/14/21, 08:45 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/21064

  9. Benni Mack commented on patch set 2 V +1 CR +1 12/14/21, 08:50

    Reply

    Done
  10. Nikita Hovratov voted on patch set 2 V +1 CR +1 12/14/21, 08:57

  11. Oli Bartsch voted on patch set 2 V +2 CR +2 12/14/21, 09:33

  12. Oli Bartsch merged patch set 3 12/14/21, 09:33