-
Notifications
You must be signed in to change notification settings - Fork 0
/
ext_tables.php
62 lines (56 loc) · 2.08 KB
/
ext_tables.php
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
<?php
if (!defined('TYPO3_MODE')) {
die ('Access denied.');
}
/***************
* Add plugins
*/
\TYPO3\CMS\Extbase\Utility\ExtensionUtility::registerPlugin(
$_EXTKEY,
'Tab',
'LLL:EXT:elements/Resources/Private/Language/locallang_be.xml:plugin.tab'
);
\TYPO3\CMS\Extbase\Utility\ExtensionUtility::registerPlugin(
$_EXTKEY,
'Accordion',
'LLL:EXT:elements/Resources/Private/Language/locallang_be.xml:plugin.accordion'
);
/***************
* Add fields to TCA
*/
$tempColumns = Array(
'element_relation' => array(
'exclude' => 1,
'label' => 'LLL:EXT:elements/Resources/Private/Language/locallang_be.xml:tt_content.element_relation',
'config' => array(
'type' => 'inline',
'allowed' => 'tt_content',
'foreign_table' => 'tt_content',
'foreign_record_defaults' => array(
'colPos' => '99'
),
'minitems' => 0,
'maxitems' => 10,
'appearance' => array(
'collapseAll' => 1,
'expandSingle' => 1,
'levelLinksPosition' => 'bottom',
'useSortable' => 1,
'showPossibleLocalizationRecords' => 1,
'showRemovedLocalizationRecords' => 1,
'showAllLocalizationLink' => 1,
'showSynchronizationLink' => 1,
'enabledControls' => array(
'info' => FALSE,
)
)
)
),
);
\TYPO3\CMS\Core\Utility\ExtensionManagementUtility::addTCAcolumns('tt_content', $tempColumns, 1);
$TCA['tt_content']['types']['elements_tab']['showitem'] = '--palette--;LLL:EXT:cms/locallang_ttc.xml:palette.general;general, element_relation, --div--;LLL:EXT:cms/locallang_ttc.xml:tabs.appearance, --palette--;LLL:EXT:cms/locallang_ttc.xml:palette.frames;frames, --div--;LLL:EXT:cms/locallang_ttc.xml:tabs.access, --palette--;LLL:EXT:cms/locallang_ttc.xml:palette.visibility;visibility, --palette--;LLL:EXT:cms/locallang_ttc.xml:palette.access;access, --div--;LLL:EXT:cms/locallang_ttc.xml:tabs.extended';
$TCA['tt_content']['types']['elements_accordion']['showitem'] = $TCA['tt_content']['types']['elements_tab']['showitem'];
/***************
* Default TypoScript
*/
\TYPO3\CMS\Core\Utility\ExtensionManagementUtility::addStaticFile($_EXTKEY, 'Configuration/TypoScript', 'Elements');