[TASK] Streamline ext:redirects auto-create chain
Changing the slugs of pages automatically creates redirects, if ext:redirects is installed and that feature has not been disabled. Detecting and handling this has been based on the `slug` value from the page record. There are some valid use cases which would benefit from the one or other good placed event. Another use case would be to create a redirect with a real build source path, thus respecting configured site route enhancers and decorators. Creating multiple redirects based on different arguments and typeNum may be another use case. This change acts as a preparation for upcoming features. Thus, it changes the passed through dataset in a way to transport valuable data. Handling and consuming methods have been adjusted. Pointing out possible places for events are added, which makes the need for the changes more obvious. Resolves: #99188 Releases: main Change-Id: Id928dc65bca27dc93164290dbdaba5e6723dbebb Reviewed-on: https://review.typo3.org/c/Packages/TYPO3.CMS/+/76816 Reviewed-by:Nikita Hovratov <nikita.h@live.de> Tested-by:
core-ci <typo3@b13.com> Tested-by:
Nikita Hovratov <nikita.h@live.de> Reviewed-by:
Stefan Bürk <stefan@buerk.tech> Tested-by:
Benni Mack <benni@typo3.org> Reviewed-by:
Benni Mack <benni@typo3.org> Tested-by:
Stefan Bürk <stefan@buerk.tech>
Showing
- typo3/sysext/redirects/Classes/Hooks/DataHandlerSlugUpdateHook.php 14 additions, 18 deletions...ext/redirects/Classes/Hooks/DataHandlerSlugUpdateHook.php
- typo3/sysext/redirects/Classes/RedirectUpdate/PlainSlugReplacementRedirectSource.php 47 additions, 0 deletions...ses/RedirectUpdate/PlainSlugReplacementRedirectSource.php
- typo3/sysext/redirects/Classes/RedirectUpdate/RedirectSourceCollection.php 50 additions, 0 deletions...rects/Classes/RedirectUpdate/RedirectSourceCollection.php
- typo3/sysext/redirects/Classes/RedirectUpdate/RedirectSourceInterface.php 29 additions, 0 deletions...irects/Classes/RedirectUpdate/RedirectSourceInterface.php
- typo3/sysext/redirects/Classes/RedirectUpdate/SlugRedirectChangeItem.php 102 additions, 0 deletions...directs/Classes/RedirectUpdate/SlugRedirectChangeItem.php
- typo3/sysext/redirects/Classes/RedirectUpdate/SlugRedirectChangeItemFactory.php 66 additions, 0 deletions.../Classes/RedirectUpdate/SlugRedirectChangeItemFactory.php
- typo3/sysext/redirects/Classes/Service/SlugService.php 90 additions, 62 deletionstypo3/sysext/redirects/Classes/Service/SlugService.php
- typo3/sysext/redirects/Tests/Functional/Service/Fixtures/SlugServiceTest_pages_test1.csv 10 additions, 10 deletions...nctional/Service/Fixtures/SlugServiceTest_pages_test1.csv
- typo3/sysext/redirects/Tests/Functional/Service/Fixtures/SlugServiceTest_pages_test2.csv 1 addition, 1 deletion...nctional/Service/Fixtures/SlugServiceTest_pages_test2.csv
- typo3/sysext/redirects/Tests/Functional/Service/Fixtures/SlugServiceTest_pages_test3.csv 1 addition, 1 deletion...nctional/Service/Fixtures/SlugServiceTest_pages_test3.csv
- typo3/sysext/redirects/Tests/Functional/Service/SlugServiceTest.php 48 additions, 18 deletions...xt/redirects/Tests/Functional/Service/SlugServiceTest.php
- typo3/sysext/redirects/Tests/Unit/RedirectUpdate/RedirectSourceCollectionTest.php 67 additions, 0 deletions...ests/Unit/RedirectUpdate/RedirectSourceCollectionTest.php
- typo3/sysext/redirects/Tests/Unit/RedirectUpdate/SlugRedirectChangeItemTest.php 62 additions, 0 deletions.../Tests/Unit/RedirectUpdate/SlugRedirectChangeItemTest.php
Please register or sign in to comment