Skip to content

Commit

Permalink
[TASK] created partner logo element
Browse files Browse the repository at this point in the history
  • Loading branch information
codefather007 committed Apr 8, 2024
1 parent 15b604d commit 5d5ab60
Show file tree
Hide file tree
Showing 2 changed files with 46 additions and 0 deletions.
36 changes: 36 additions & 0 deletions local_packages/success/Configuration/TCA/Overrides/tt_content.php
Original file line number Diff line number Diff line change
Expand Up @@ -255,3 +255,39 @@
];

$GLOBALS['TCA']['tt_content']['ctrl']['typeicon_classes']['success_gallery'] = 'content-image';

// Partner Logo Element
\TYPO3\CMS\Core\Utility\ExtensionManagementUtility::addTcaSelectItem(
'tt_content',
'CType',
[
'label' => 'LLL:EXT:success/Resources/Private/Language/locallang_ctypes.xlf:partner',
'value' => 'success_partner',
'icon' => 'actions-briefcase',
'group' => 'default',
'description' => 'LLL:EXT:success/Resources/Private/Language/locallang_ctypes.xlf:partner.description',
]
);

$tx_success_partner = [
'tx_success_partner' => [
'exclude' => 0,
'label' => 'LLL:EXT:success/Resources/Private/Language/locallang_ctypes.xlf:partner.item',
'config' => [
'type' => 'file',
'allowed' => 'common-image-types',
'maxitems' => 2,
],
]
];

\TYPO3\CMS\Core\Utility\ExtensionManagementUtility::addTCAcolumns('tt_content', $tx_success_partner);

$GLOBALS['TCA']['tt_content']['types']['success_partner'] = [
'showitem' => '
--div--;LLL:EXT:core/Resources/Private/Language/Form/locallang_tabs.xlf:general,
--palette--;;general,
--palette--;;headers,tx_success_partner'
];

$GLOBALS['TCA']['tt_content']['ctrl']['typeicon_classes']['success_partner'] = 'actions-briefcase';
Original file line number Diff line number Diff line change
Expand Up @@ -57,6 +57,16 @@
<source>Images</source>
</trans-unit>

<trans-unit id="partner" resname="partner">
<source>Partner Logo Element</source>
</trans-unit>
<trans-unit id="partner.description" resname="partner.description">
<source>A list of partner logos</source>
</trans-unit>
<trans-unit id="partner.item" resname="partner.item">
<source>Logos</source>
</trans-unit>

</body>
</file>
</xliff>

0 comments on commit 5d5ab60

Please sign in to comment.