-
Notifications
You must be signed in to change notification settings - Fork 3
/
ext_tables.php
executable file
·53 lines (47 loc) · 1.76 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
<?php
if (!defined('TYPO3_MODE')) {
die('Access denied.');
}
call_user_func(
function ($packageKey) {
\TYPO3\CMS\Core\Utility\ExtensionManagementUtility::addStaticFile(
$packageKey,
'Configuration/TypoScript',
'News importer'
);
\TYPO3\CMS\Core\Utility\ExtensionManagementUtility::addLLrefForTCAdescr(
'tx_newsimporter_domain_model_importsource',
'EXT:news_importer/Resources/Private/Language/locallang_csh_tx_newsimporter_domain_model_importsource.xlf'
);
// Register icons
/** @var \TYPO3\CMS\Core\Imaging\IconRegistry $iconRegistry */
$iconRegistry = \TYPO3\CMS\Core\Utility\GeneralUtility::makeInstance(
\TYPO3\CMS\Core\Imaging\IconRegistry::class
);
$iconRegistry->registerIcon(
'apps-pagetree-folder-contains-imports',
\TYPO3\CMS\Core\Imaging\IconProvider\BitmapIconProvider::class,
['source' => 'EXT:' . $packageKey . '/ext_icon.png']
);
if (TYPO3_MODE === 'BE') {
/**
* Registers a Backend Module
*/
\TYPO3\CMS\Extbase\Utility\ExtensionUtility::registerModule(
'NewsImporter',
'web',
'newsimporter',
'', // Position
[
\BeechIt\NewsImporter\Controller\AdminController::class => 'index,show,import',
],
[
'access' => 'user,group',
'icon' => 'EXT:' . $packageKey . '/ext_icon.png',
'labels' => 'LLL:EXT:' . $packageKey . '/Resources/Private/Language/locallang_be_module.xlf',
]
);
}
},
'news_importer'
);