mirror of
https://github.com/werkraum-media/events.git
synced 2024-11-14 17:36:11 +01:00
Daniel Siepmann
1929a4a566
Extbase will properly use mm sorting. But categories can't be sorted within the TCA tree component. Therefore it makes more sense to use actual sys_category sorting. In order to do so, we add our own model and pass the sorting. That way PHP can do the sorting. That's the easiest approach. Also events shouldn't contain to many categories. A performance impact should not be high. Relates: #8459
16 lines
448 B
PHP
16 lines
448 B
PHP
<?php
|
|
|
|
defined('TYPO3') or die();
|
|
|
|
(function (string $extKey, string $table) {
|
|
\TYPO3\CMS\Core\Utility\ArrayUtility::mergeRecursiveWithOverrule($GLOBALS['TCA'][$table], [
|
|
'columns' => [
|
|
'sorting' => [
|
|
'config' => [
|
|
// Allow extbase to map this column to model
|
|
'type' => 'passthrough',
|
|
],
|
|
],
|
|
],
|
|
]);
|
|
})('events', 'sys_category');
|