Review main Merged Breaking

75184[!!!][FEATURE] Add PSR-14 AfterPageTreeItemsPreparedEvent

Oli Bartsch CR +2 V +2 Hard +511 −65 updated 07/15/22, 21:34

Commit message

The new PSR-14 AfterPageTreeItemsPreparedEvent is added.
The Event gets dispatched in the TreeController and allows
to further modify the resolved and already prepared page
tree items before being returned.

The new event is directly used by EXT:workspaces to apply
the highlighting of versioned pages. Using this new event
allows to remove another cross dependency of EXT:backend.

Additionally, the hooks
$GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']['TYPO3\CMS\Workspaces\Service\WorkspaceService']['hasPageRecordVersions']
and $GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']['TYPO3\CMS\Workspaces\Service\WorkspaceService']['fetchPagesWithVersionsInTable']
are now removed, since this can now be done using the
new PSR-14 Event.

Review

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

Issues 1

Files 12

Review log 1722

  1. Oli Bartsch uploaded patch set 1 07/14/22, 19:39

  2. core-ci voted on patch set 1 V +1 07/14/22, 19:48 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/29168

  3. Oliver Klee commented on patch set 1 07/14/22, 20:11

    Please let's have tests that the hooks get called, and simple tests that the getters/setters of the hook work fine. We can steal from this change for this: https://review.typo3.org/c/Packages/TYPO3.CMS/+/74825
  4. Oliver Klee commented on patch set 1 CR -1 07/14/22, 20:14

    ModifyPagesWithVersionsInTableEvent.php:31

    Typo (also in the getter, and also in the other event class): worksapceId -> workspaceId
  5. Oli Bartsch uploaded patch set 2 07/15/22, 09:36

  6. Oli Bartsch commented on patch set 2 07/15/22, 09:40

    Reply

    Done

    ModifyPagesWithVersionsInTableEvent.php:31 Reply

    Done
  7. core-ci voted on patch set 2 V +1 07/15/22, 09:43 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/29198

  8. Andreas Kienast commented on patch set 2 CR -1 07/15/22, 09:44

    on it
  9. Andreas Kienast uploaded patch set 3 07/15/22, 09:53

  10. Andreas Kienast voted on patch set 3 V +1 CR +1 07/15/22, 09:54

  11. core-ci voted on patch set 3 V +1 07/15/22, 10:00 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/29199

  12. Benni Mack commented on patch set 3 07/15/22, 10:03

    ModifyVersionsOnPageEvent.php:23

    I think this event name is really misleading.
  13. Benni Mack voted on patch set 3 CR -1 07/15/22, 10:03

  14. Oli Bartsch uploaded patch set 4 07/15/22, 19:55

  15. core-ci voted on patch set 4 V -1 07/15/22, 20:02 Core CI is not happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/29238

  16. Oli Bartsch uploaded patch set 5 07/15/22, 20:14

  17. core-ci voted on patch set 5 V +1 07/15/22, 20:27 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/29241

  18. Oli Bartsch commented on patch set 5 07/15/22, 20:30

    ModifyVersionsOnPageEvent.php:23 Reply

    Done
  19. Jochen Roth voted on patch set 5 V +1 CR +1 07/15/22, 21:05

  20. Benni Mack voted on patch set 5 V +2 CR +2 07/15/22, 21:31

  21. Oli Bartsch voted on patch set 5 V +2 CR +2 07/15/22, 21:34

  22. Oli Bartsch merged patch set 6 07/15/22, 21:34