90521[!!!][FEATURE] Add PSR-14 Event to manipulate form creation
Commit message
Review
-
Code review CR +2 Done
- Benni Mack +2
- Oli Bartsch +1
-
Verified V +2 Done
- Benni Mack +2
- Oli Bartsch +1
- core-ci +1 CI
Issues 1
Files 7
- typo3/sysext/core/Documentation/Changelog/14.0/Breaking-107343-RemovedBeforeFormCreateHook.rstnew+40 −0
- typo3/sysext/core/Documentation/Changelog/14.0/Feature-107343-IntroducePSR14BeforeFormIsCreatedEvent.rstnew+53 −0
- typo3/sysext/form/Classes/Controller/FormManagerController.php+6 −9
- typo3/sysext/form/Classes/Event/BeforeFormIsCreatedEvent.php5new+35 −0
- typo3/sysext/form/Tests/Functional/Controller/Fixtures/DatabaseImports/sys_file_storage.csvnew+4 −0
- typo3/sysext/form/Tests/Functional/Controller/FormManagerControllerTest.php+59 −2
- typo3/sysext/install/Configuration/ExtensionScanner/Php/ArrayDimensionMatcher.php+6 −0
Review log 2432
Show 57 earlier messages
-
Josua Vogel uploaded patch set 1 08/30/25, 13:22
-
core-ci voted on patch set 1 V -1 08/30/25, 13:30 Core CI is not happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/84045
-
Josua Vogel uploaded patch set 2
V -108/30/25, 13:35 -
core-ci voted on patch set 2 V +1 08/30/25, 13:43 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/84046
-
Chris Müller commented on patch set 2 08/30/25, 15:46
BeforeFormCreateHookProvider.php:26I assume, you mean v15? Additionally, you can still be breaking at this time, so IMHO you can drop the hook completely. Extension authors can implement the hook and the event side-by-side to be compatible with v13 and v14. -
Josua Vogel uploaded patch set 3
V +109/01/25, 05:51 -
Josua Vogel commented on patch set 3 09/01/25, 05:53
BeforeFormCreateEvent.php:38ReplyDoneBeforeFormCreateHookProvider.php:26ReplyWell, I talked with Oli beforehand. You´re right, but this way is the better strategy.
-
core-ci voted on patch set 3 V +1 09/01/25, 05:59 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/84125
-
Josua Vogel commented on patch set 3 09/01/25, 06:23
BeforeFormCreateHookProvider.php:26ReplyDone -
Benni Mack commented on patch set 3 CR -1 09/02/25, 09:28
Hey Josua, thanks for the patch. how about we'll migrate all hooks to events at once? In addition, let's remove the hook directly (= Breaking instead of deprecation). We can do this because we're before 14.0. Plus: Extension authors can be compatible without a deprecation notice by implementing the hook (v13 and before) AND the event listener in v14+. Feel free to use better names for the Events instead of a 1:1 copy. "BeforeFormCreateEvent" => "BeforeFormIsCreatedEvent" (or even "BeforeFormIsInitiallyPersistedEvent") -
Josua Vogel commented on patch set 3 09/02/25, 12:59
Reply
Hi Benni, thx! Yes I can do all events at once. Oli told me to split 😊 so what´s the preferred way? And yes, I will drop the hook and make this breaking -
Benni Mack commented on patch set 3 09/02/25, 13:11
Reply
OK. Just go one at a time! -
Josua Vogel uploaded patch set 4
CR -1V +109/02/25, 14:40 -
core-ci voted on patch set 4 V +1 09/02/25, 14:47 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/84259
-
Christiane Helmchen voted on patch set 4 V +1 09/02/25, 16:56
-
Christiane Helmchen voted on patch set 4 CR +1 09/02/25, 16:57
-
Oli Bartsch commented on patch set 4 V -1 09/02/25, 17:55
Feature-107343-IntroducePSR14EventBeforeFormCreate.rst:17I suggest to add sth. like "The event is dispatched right before a new form is created in the backend." People might not know the hook and should still understand what this event is for / where it is dispatched. Please also list and describe all provided information by the event.Feature-107343-IntroducePSR14EventBeforeFormCreate.rst:22An example event listener could look likeFeature-107343-IntroducePSR14EventBeforeFormCreate.rst:26This is not used :)Feature-107343-IntroducePSR14EventBeforeFormCreate.rst:29Let's use method arguments so we show that a class can contain multiple listeners.BeforeFormIsCreatedEvent.php:21This is wrong.BeforeFormIsCreatedEvent.php:33Do we really want to allow modifying the `$formPersistenceIdentifier`? -
Josua Vogel commented on patch set 4 09/02/25, 18:31
BeforeFormIsCreatedEvent.php:33ReplyIt's not possible at the moment, but I found it to be a useful addition. However, I'm fundamentally indifferent about it. Could be a great addition to modify the save path by a custom logic. -
Josua Vogel uploaded patch set 5
CR +1V +109/02/25, 18:35 -
Josua Vogel uploaded patch set 6 09/02/25, 18:35
-
Josua Vogel commented on patch set 5 09/02/25, 18:36
Feature-107343-IntroducePSR14EventBeforeFormCreate.rst:17ReplyDoneFeature-107343-IntroducePSR14EventBeforeFormCreate.rst:22ReplyDoneFeature-107343-IntroducePSR14EventBeforeFormCreate.rst:26ReplyDoneFeature-107343-IntroducePSR14EventBeforeFormCreate.rst:29ReplyDoneBeforeFormIsCreatedEvent.php:21ReplyDone -
core-ci voted on patch set 5 V +1 09/02/25, 18:43 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/84274
-
core-ci voted on patch set 6 V +1 09/02/25, 18:44 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/84275
-
Oli Bartsch uploaded patch set 7
V +109/03/25, 09:19 -
Oli Bartsch commented on patch set 7 09/03/25, 09:19
BeforeFormIsCreatedEvent.php:33ReplyDone -
core-ci voted on patch set 7 V -1 09/03/25, 09:27 Core CI is not happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/84311
-
Oli Bartsch uploaded patch set 8
V -109/03/25, 09:34 -
core-ci voted on patch set 8 V +1 09/03/25, 09:42 Core CI is happy: https://git.typo3.org/typo3/CI/cms/-/pipelines/84314
-
Oli Bartsch voted on patch set 8 CR +1 V +1 09/03/25, 09:50
-
Benni Mack voted on patch set 8 CR +2 V +2 09/03/25, 10:07
-
Benni Mack merged patch set 9 09/03/25, 10:07
-
Lina Wolf commented on patch set 9 09/06/25, 11:32
Unresolved
Please review documentation at https://github.com/TYPO3-Documentation/TYPO3CMS-Reference-CoreApi/pull/6006 Also needs to be documented in the extension manual: https://forge.typo3.org/issues/107405?issue_count=10&issue_position=1&next_issue_id=107241
BeforeFormCreateEvent.php:38