Merge conflict Gerrit cannot merge this change. It needs a rebase onto main.

Review main Ready for review Quiet

96319[FEATURE] Undo operations from their notification

Oli Bartsch CR 0 V +1 Nightmare +2885 −88 updated 10/21/26, 10:39

Commit message

Commands processed through the record_process route, such as
deleting, moving, copying or pasting records, are confirmed by a
notification with an undo button, which reverts the whole
operation. Once undone, it offers to redo it. Modules confirming an
operation themselves, as the move wizards do, add the undo button
to their own notification instead of showing a second one.

The Records module processes its actions, deleting, moving records
up and down or between levels and pasting from the clipboard,
through record_process instead of the tce_db redirect, so they
offer the undo as well.

The undo is all or nothing and runs in a transaction. It is refused
when it cannot be done cleanly: another user, records the user may
not see or modify, changes made since, permanent deletions, more
than 500 records, operations older than an hour, or workspaces.

The record history now restores content deleted along with its page
in the same operation, which it counted as deleted twice before.
sys_history gets the indexed field correlation_scope, so operations
are found without a LIKE on the correlation id, and the queries the
undo needs live in OperationHistoryRepository.

Test this change

Run a command in your clone of the TYPO3 Core. Then try what the change does and vote on Verified in Gerrit. How to review a patch

Check out patch set 8
git fetch https://review.typo3.org/Packages/TYPO3.CMS refs/changes/19/96319/8 && git checkout FETCH_HEAD
Cherry-pick onto main
git fetch https://review.typo3.org/Packages/TYPO3.CMS refs/changes/19/96319/8 && git cherry-pick FETCH_HEAD

Review

  • Code review CR 0 Needs a vote
  • Verified V +1 Needs a vote
    • Garvin Hicking +1
    • core-ci +1 CI

Issues 3

Files 50

Show 30 more files

Review log 1220

  1. Oli Bartsch uploaded patch set 1 10/02/26, 15:31

  2. core-ci voted on patch set 1 V -1 10/02/26, 15:43 Core CI is not happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/109963

  3. Oli Bartsch uploaded patch set 2 V -1 10/02/26, 19:42

  4. core-ci voted on patch set 2 V +1 10/02/26, 19:50 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/109991

  5. Oli Bartsch rebased onto patch set 3 V +1 10/05/26, 15:02

  6. core-ci voted on patch set 3 V +1 10/05/26, 15:15 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/110124

  7. Oli Bartsch uploaded patch set 4 V +1 10/07/26, 20:25

  8. core-ci voted on patch set 4 V +1 10/07/26, 20:45 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/110407

  9. Oli Bartsch rebased onto patch set 5 V +1 10/09/26, 17:55

  10. core-ci voted on patch set 5 V +1 10/09/26, 18:06 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/110664

  11. Oli Bartsch uploaded patch set 6 V +1 10/13/26, 07:34

  12. core-ci voted on patch set 6 V +1 10/13/26, 07:48 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/110985

  13. Oli Bartsch uploaded patch set 7 V +1 10/19/26, 09:36

  14. core-ci voted on patch set 7 V +1 10/19/26, 09:58 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/111615

  15. Simon Schaufelberger commented on patch set 7 CR +1 V +1 10/19/26, 21:24

    works great!
  16. Garvin Hicking commented on patch set 7 10/20/26, 07:51

    Notifications only show up for the "Layout" module while with this commit message I would expect it in the "Records" module. We might want/need to use the notifications in the record module too for consistency, unless this is intentional?
  17. Oli Bartsch uploaded patch set 8 CR +1 V +1 10/21/26, 07:15

  18. core-ci voted on patch set 8 V +1 10/21/26, 07:23 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/111973

  19. Oli Bartsch commented on patch set 8 10/21/26, 07:37

    Reply

    Thanks, good catch. The Records module still ran its row actions through the tce_db redirect, which cannot carry the undo offer. With this patch set it processes deleting, moving up/down and between levels and pasting from the clipboard through record_process, so all of them offer the undo.
  20. Garvin Hicking commented on patch set 8 V +1 10/21/26, 10:39

    This works nicely for me. I can't judge any of the TS though.