[FEATURE] Reusable getCategoryFieldsForTable itemsProcFunc
Allow the the method CategoryRegistry->getCategoryFieldItems() to be used as itemsProcFunc for select fields in the TCA in arbitary contexts by introducing a new categoryFieldsTable configuration in the config section of a column in the TCA. This configuration key can either consist of a single string containing the name of the table or a configuration array to define additional conditions that need to be true so that a configured table is used. The condition matching is based on the displayCond functionality of the TCA. To make use of the existing functionality the code for matching the display conditions is extracted from the form data provider to a new DisplayConditionEvaluator utility class. Resolves: #53045 Releases: master Change-Id: I128cbeb6747a8f83e68cdaaaafbc3ab5901353d4 Reviewed-on: https://review.typo3.org/24968 Tested-by:TYPO3com <no-reply@typo3.com> Reviewed-by:
Anja Leichsenring <aleichsenring@ab-softlab.de> Tested-by: Anja Leic...
Showing
- typo3/sysext/backend/Classes/Form/FormDataProvider/EvaluateDisplayConditions.php 17 additions, 311 deletions...asses/Form/FormDataProvider/EvaluateDisplayConditions.php
- typo3/sysext/backend/Classes/Form/Utility/DisplayConditionEvaluator.php 338 additions, 0 deletions...ackend/Classes/Form/Utility/DisplayConditionEvaluator.php
- typo3/sysext/core/Classes/Category/CategoryRegistry.php 113 additions, 17 deletionstypo3/sysext/core/Classes/Category/CategoryRegistry.php
- typo3/sysext/core/Documentation/Changelog/master/Breaking-53045-GetCategoryFieldsForTableMethodRemovedFromCategoryRegistry.rst 36 additions, 0 deletions...tegoryFieldsForTableMethodRemovedFromCategoryRegistry.rst
- typo3/sysext/core/Documentation/Changelog/master/Feature-53045-CategorizedFieldsForTableItemsProcFuncInCategoryRegistry.rst 58 additions, 0 deletions...egorizedFieldsForTableItemsProcFuncInCategoryRegistry.rst
- typo3/sysext/core/Tests/Unit/Category/CategoryRegistryTest.php 152 additions, 0 deletions.../sysext/core/Tests/Unit/Category/CategoryRegistryTest.php
- typo3/sysext/frontend/Configuration/TCA/tt_content.php 11 additions, 1 deletiontypo3/sysext/frontend/Configuration/TCA/tt_content.php
Please register or sign in to comment