forked from teaminmedias-pluswerk/ke_search
-
Notifications
You must be signed in to change notification settings - Fork 0
/
ext_tables.php
57 lines (51 loc) · 2.18 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
<?php
if (!defined('TYPO3_MODE')) {
die('Access denied.');
}
(function () {
// add help file
\TYPO3\CMS\Core\Utility\ExtensionManagementUtility::addLLrefForTCAdescr(
'tx_kesearch_filters',
'EXT:ke_search/locallang_csh.xml'
);
// add module
if (\TYPO3\CMS\Core\Utility\VersionNumberUtility::convertVersionNumberToInteger(TYPO3_branch) >=
\TYPO3\CMS\Core\Utility\VersionNumberUtility::convertVersionNumberToInteger('10.0')
) {
$extensionName = 'ke_search';
$controller = \TeaminmediasPluswerk\KeSearch\Controller\BackendModuleController::class;
} else {
$extensionName = 'TeaminmediasPluswerk.ke_search';
$controller = 'BackendModule';
}
\TYPO3\CMS\Extbase\Utility\ExtensionUtility::registerModule(
$extensionName,
'web',
'backend_module',
'',
array(
$controller =>
'startIndexing,indexedContent,indexTableInformation,'
. 'searchwordStatistics,clearSearchIndex,lastIndexingReport,alert',
),
array(
'access' => 'user,group',
'icon' => 'EXT:ke_search/Resources/Public/Icons/moduleicon.svg',
'labels' => 'LLL:EXT:ke_search/Resources/Private/Language/locallang_mod.xml',
)
);
// add scheduler task
$GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']['scheduler']['tasks'][\TeaminmediasPluswerk\KeSearch\Scheduler\IndexerTask::class]
= array(
'extension' => 'ke_search',
'title' => 'Indexing process for ke_search (DEPRECATED, please use "Execute console commands" --> "ke_search:indexing" instead)',
'description' => 'This task updates the ke_search index (DEPRECATED, please use "Execute console commands" --> "ke_search:indexing" instead)'
);
/** @var \TYPO3\CMS\Core\Imaging\IconRegistry $iconRegistry */
$iconRegistry = \TYPO3\CMS\Core\Utility\GeneralUtility::makeInstance(\TYPO3\CMS\Core\Imaging\IconRegistry::class);
$iconRegistry->registerIcon(
'ext-kesearch-wizard-icon',
'TYPO3\CMS\Core\Imaging\IconProvider\BitmapIconProvider',
['source' => 'EXT:ke_search/Resources/Public/Icons/moduleicon.svg']
);
})();