From 5e476ad6dd41b72b693fdc1f4a665b7650e56339 Mon Sep 17 00:00:00 2001 From: Christian Kuhn <lolli@schwarzbu.ch> Date: Mon, 20 Dec 2021 17:10:32 +0100 Subject: [PATCH] [TASK] Move BackendController templates to one place MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit BackendController renders "Main.html" as central backend skeleton, plus "Topbar.html" and "MainModule.html". The patch moved the templates into one folder. Resolves: #96404 Releases: main Change-Id: I485d9ff03e457d78c8454e36ac893fbbc1ffe77c Reviewed-on: https://review.typo3.org/c/Packages/TYPO3.CMS/+/72746 Tested-by: core-ci <typo3@b13.com> Tested-by: Andreas Fernandez <a.fernandez@scripting-base.de> Tested-by: Christian Kuhn <lolli@schwarzbu.ch> Tested-by: Stefan Bürk <stefan@buerk.tech> Reviewed-by: Andreas Fernandez <a.fernandez@scripting-base.de> Reviewed-by: Christian Kuhn <lolli@schwarzbu.ch> Reviewed-by: Stefan Bürk <stefan@buerk.tech> --- .../backend/Classes/Controller/BackendController.php | 9 ++------- .../{ModuleMenu/Main.html => Backend/ModuleMenu.html} | 0 .../Private/{Partials => Templates}/Backend/Topbar.html | 0 3 files changed, 2 insertions(+), 7 deletions(-) rename typo3/sysext/backend/Resources/Private/Templates/{ModuleMenu/Main.html => Backend/ModuleMenu.html} (100%) rename typo3/sysext/backend/Resources/Private/{Partials => Templates}/Backend/Topbar.html (100%) diff --git a/typo3/sysext/backend/Classes/Controller/BackendController.php b/typo3/sysext/backend/Classes/Controller/BackendController.php index e9305acc3cb3..6b34259c90bc 100644 --- a/typo3/sysext/backend/Classes/Controller/BackendController.php +++ b/typo3/sysext/backend/Classes/Controller/BackendController.php @@ -60,11 +60,6 @@ class BackendController */ protected $templatePath = 'EXT:backend/Resources/Private/Templates/'; - /** - * @var string - */ - protected $partialPath = 'EXT:backend/Resources/Private/Partials/'; - protected BackendModuleRepository $backendModuleRepository; protected PageRenderer $pageRenderer; protected IconFactory $iconFactory; @@ -203,7 +198,7 @@ class BackendController */ protected function renderTopbar() { - $view = $this->getFluidTemplateObject($this->partialPath . 'Backend/Topbar.html'); + $view = $this->getFluidTemplateObject($this->templatePath . 'Backend/Topbar.html'); // Extension Configuration to find the TYPO3 logo in the left corner $extConf = GeneralUtility::makeInstance(ExtensionConfiguration::class)->get('backend'); @@ -442,7 +437,7 @@ class BackendController */ protected function generateModuleMenu() { - $view = $this->getFluidTemplateObject($this->templatePath . 'ModuleMenu/Main.html'); + $view = $this->getFluidTemplateObject($this->templatePath . 'Backend/ModuleMenu.html'); $view->assign('modules', $this->moduleStorage); return $view->render(); } diff --git a/typo3/sysext/backend/Resources/Private/Templates/ModuleMenu/Main.html b/typo3/sysext/backend/Resources/Private/Templates/Backend/ModuleMenu.html similarity index 100% rename from typo3/sysext/backend/Resources/Private/Templates/ModuleMenu/Main.html rename to typo3/sysext/backend/Resources/Private/Templates/Backend/ModuleMenu.html diff --git a/typo3/sysext/backend/Resources/Private/Partials/Backend/Topbar.html b/typo3/sysext/backend/Resources/Private/Templates/Backend/Topbar.html similarity index 100% rename from typo3/sysext/backend/Resources/Private/Partials/Backend/Topbar.html rename to typo3/sysext/backend/Resources/Private/Templates/Backend/Topbar.html -- GitLab