[BUGFIX] Do not scroll on top using actions on multipleSideBySide
[Packages/TYPO3.CMS.git] / typo3 / sysext / install / ext_tables.php
index e7cbcfe..58fa1db 100644 (file)
@@ -1,23 +1,29 @@
 <?php
-if (!defined('TYPO3_MODE')) {
-       die('Access denied.');
-}
+defined('TYPO3_MODE') or die();
+
 if (TYPO3_MODE === 'BE') {
-       // Register report module additions
-       $GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']['reports']['tx_reports']['status']['providers']['typo3'][] = 'TYPO3\\CMS\\Install\\Report\\InstallStatusReport';
-       $GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']['reports']['tx_reports']['status']['providers']['system'][] = 'TYPO3\\CMS\\Install\\Report\\EnvironmentStatusReport';
+    // Register report module additions
+    $GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']['reports']['tx_reports']['status']['providers']['typo3'][] = \TYPO3\CMS\Install\Report\InstallStatusReport::class;
+    $GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']['reports']['tx_reports']['status']['providers']['security'][] = \TYPO3\CMS\Install\Report\SecurityStatusReport::class;
+
+    // Only add the environment status report if not in CLI mode
+    if (TYPO3_REQUESTTYPE & TYPO3_REQUESTTYPE_CLI) {
+        $GLOBALS['TYPO3_CONF_VARS']['SC_OPTIONS']['reports']['tx_reports']['status']['providers']['system'][] = \TYPO3\CMS\Install\Report\EnvironmentStatusReport::class;
+    }
 
-       // Register backend module
-       \TYPO3\CMS\Extbase\Utility\ExtensionUtility::registerModule(
-               'TYPO3.CMS.' . $_EXTKEY,
-               'system',
-               'install', '', array(
-                       'BackendModule' => 'index, showEnableInstallToolButton, enableInstallTool',
-               ),
-               array(
-                       'access' => 'admin',
-                       'icon' => 'EXT:' . $_EXTKEY . '/Resources/Public/Images/Icon/BackendModule.gif',
-                       'labels' => 'LLL:EXT:' . $_EXTKEY . '/Resources/Private/Language/BackendModule.xlf',
-               )
-       );
+    \TYPO3\CMS\Core\Utility\ExtensionManagementUtility::addModule(
+        'system',
+        'extinstall',
+        '',
+        '',
+        array(
+            'routeTarget' => \TYPO3\CMS\Install\Controller\BackendModuleController::class . '::index',
+            'access' => 'admin',
+            'name' => 'system_extinstall',
+            'icon' => 'EXT:install/Resources/Public/Icons/module-install.svg',
+            'labels' => array(
+                'll_ref' => 'LLL:EXT:install/Resources/Private/Language/BackendModule.xlf',
+            ),
+        )
+    );
 }