From 2a87f1773ae74bd5a1fcacb810d1b77d6c14289d Mon Sep 17 00:00:00 2001 From: David Steeb Date: Tue, 2 Jun 2020 16:37:41 +0200 Subject: [PATCH] [TASK] Update palettes configuration --- Configuration/TCA/Overrides/tt_content.php | 22 +++++++++------------- 1 file changed, 9 insertions(+), 13 deletions(-) diff --git a/Configuration/TCA/Overrides/tt_content.php b/Configuration/TCA/Overrides/tt_content.php index 45fe088..40676cd 100644 --- a/Configuration/TCA/Overrides/tt_content.php +++ b/Configuration/TCA/Overrides/tt_content.php @@ -1,6 +1,5 @@ [ 'label' => 'LLL:EXT:cta/Resources/Private/Language/locallang_db.xlf:link.formlabel', @@ -40,7 +39,6 @@ ], ]); - \TYPO3\CMS\Core\Utility\ExtensionManagementUtility::addTcaSelectItem( 'tt_content', 'CType', @@ -49,17 +47,15 @@ 'after' ); -\TYPO3\CMS\Core\Utility\ExtensionManagementUtility::addFieldsToPalette( - 'tt_content', - 'linklabel', - 'link,linklabel' -); +$GLOBALS['TCA']['tt_content']['palettes']['linklabel'] = [ + 'showitem' => 'link,linklabel', + 'label' => 'LLL:EXT:cta/Resources/Private/Language/locallang_db.xlf:palettes.linklabel.title' +]; -\TYPO3\CMS\Core\Utility\ExtensionManagementUtility::addFieldsToPalette( - 'tt_content', - 'linklabelconfig', - 'link,linklabel,linkconfig' -); +$GLOBALS['TCA']['tt_content']['palettes']['linklabelconfig'] = [ + 'showitem' => 'link,linklabel,linkconfig', + 'label' => 'LLL:EXT:cta/Resources/Private/Language/locallang_db.xlf:palettes.linklabelconfig.title' +]; // use the same configuration for visible backend fields as "Textmedia" if (!$GLOBALS['TCA']['tt_content']['defaultTypeConfiguration']) { @@ -70,6 +66,6 @@ $GLOBALS['TCA']['tt_content']['types']['cta'] = [ 'showitem' => $GLOBALS['TCA']['tt_content']['defaultTypeConfiguration']['begin'] . ' layout, - --palette--;LLL:EXT:cta/Resources/Private/Language/locallang_db.xlf:palettes.linklabelconfig.title;linklabelconfig, + --palette--;;linklabelconfig, ' . $GLOBALS['TCA']['tt_content']['defaultTypeConfiguration']['end'] ];