[TASK] Add Site Configuration to ConfigurationController 44/56644/5
authorSimon Gilli <typo3@gilbertsoft.org>
Fri, 13 Apr 2018 01:26:06 +0000 (03:26 +0200)
committerTymoteusz Motylewski <t.motylewski@gmail.com>
Wed, 30 May 2018 19:32:43 +0000 (21:32 +0200)
Add the Site Configuration to the ConfigurationController to
simplify debugging and enable its inspection at the backend.

Resolves: #84709
Releases: master
Change-Id: Ib0720f372a2d27873fda9931c8753c7ed6a98750
Reviewed-on: https://review.typo3.org/56644
Reviewed-by: Mathias Brodala <mbrodala@pagemachine.de>
Tested-by: Mathias Brodala <mbrodala@pagemachine.de>
Tested-by: TYPO3com <no-reply@typo3.com>
Reviewed-by: Tymoteusz Motylewski <t.motylewski@gmail.com>
Tested-by: Tymoteusz Motylewski <t.motylewski@gmail.com>
typo3/sysext/lowlevel/Classes/Controller/ConfigurationController.php
typo3/sysext/lowlevel/Resources/Private/Language/locallang.xlf

index ed6275c..50c9e32 100644 (file)
@@ -17,6 +17,7 @@ namespace TYPO3\CMS\Lowlevel\Controller;
 
 use Psr\Http\Message\ResponseInterface;
 use Psr\Http\Message\ServerRequestInterface;
+use TYPO3\CMS\Backend\Configuration\SiteTcaConfiguration;
 use TYPO3\CMS\Backend\Routing\Router;
 use TYPO3\CMS\Backend\Template\ModuleTemplate;
 use TYPO3\CMS\Core\Authentication\BackendUserAuthentication;
@@ -113,6 +114,10 @@ class ConfigurationController
             'label' => 'httpMiddlewareStacks',
             'type' => 'httpMiddlewareStacks',
         ],
+        'siteConfiguration' => [
+            'label' => 'siteConfiguration',
+            'type' => 'siteConfiguration',
+        ],
     ];
 
     /**
@@ -238,6 +243,8 @@ class ConfigurationController
                 // reversing the array allows the admin to read the stack from top to bottom
                 $renderArray[$stackName] = array_reverse($stackResolver->resolve($stackName));
             }
+        } elseif ($selectedTreeDetails['type'] === 'siteConfiguration') {
+            $renderArray = GeneralUtility::makeInstance(SiteTcaConfiguration::class)->getTca();
         } else {
             throw new \RuntimeException('Unknown array type "' . $selectedTreeDetails['type'] . '"', 1507845662);
         }
index ed39528..93ca8c8 100644 (file)
@@ -36,6 +36,9 @@
                        <trans-unit id="httpMiddlewareStacks">
                                <source>HTTP Middlewares (PSR-15)</source>
                        </trans-unit>
+                       <trans-unit id="siteConfiguration">
+                               <source>Site Configuration</source>
+                       </trans-unit>
                        <trans-unit id="t3services">
                                <source>$GLOBALS['T3_SERVICES'] (Registered Services)</source>
                        </trans-unit>