-
Notifications
You must be signed in to change notification settings - Fork 9
/
Copy pathext_localconf.php
29 lines (25 loc) · 1.13 KB
/
ext_localconf.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
<?php
/**
* General ext_localconf file and also an example for your own extension
*
* @category Extension
* @package Calendarize
* @author Tim Lochmüller
*/
defined('TYPO3') or exit();
\HDNET\Calendarize\Register::extLocalconf(\HDNET\CalendarizeNews\Register::getConfiguration());
$extensionConfiguration = \TYPO3\CMS\Core\Utility\GeneralUtility::makeInstance(
\TYPO3\CMS\Core\Configuration\ExtensionConfiguration::class
)->get('calendarize_news');
$xclasses = [
\HDNET\CalendarizeNews\Xclass\NewsLinkViewHelper::class => \GeorgRinger\News\ViewHelpers\LinkViewHelper::class,
];
if (isset($extensionConfiguration['replaceNewsRepositoryByIndexSelection']) && (bool)$extensionConfiguration['replaceNewsRepositoryByIndexSelection']) {
$xclasses[\HDNET\CalendarizeNews\Xclass\NewsController::class] = \GeorgRinger\News\Controller\NewsController::class;
$xclasses[\HDNET\CalendarizeNews\Xclass\NewsRepository::class] = \GeorgRinger\News\Domain\Repository\NewsRepository::class;
}
foreach ($xclasses as $target => $source) {
$GLOBALS['TYPO3_CONF_VARS']['SYS']['Objects'][$source] = [
'className' => $target,
];
}