From 3eb568e62e92dc4ad5e95a04d11ca2ceb8fcf0eb Mon Sep 17 00:00:00 2001 From: Marc Bastian Heinrichs Date: Thu, 24 Nov 2016 10:35:51 +0100 Subject: [PATCH] [BUGFIX] Load ts in backend context from the right page We fake GET id here to trick the extbase BackendConfigurationManager. It uses the first found site root fetching the ts if no id present. --- Classes/Backend/TceForms.php | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/Classes/Backend/TceForms.php b/Classes/Backend/TceForms.php index 39925b8..30592ba 100644 --- a/Classes/Backend/TceForms.php +++ b/Classes/Backend/TceForms.php @@ -31,7 +31,18 @@ public function renderTemplateMenu(&$params, &$tsObj) $configurationManager = $this->getObjectManager()->get(BackendConfigurationManager::class); + // fake GET[id] to get the ts configuration from the right page + $saveGet = null; + if (isset($_GET['id'])) { + $saveGet = $_GET['id']; + } + $_GET['id'] = $params['row']['pid']; $setup = $configurationManager->getTypoScriptSetup(); + if ($saveGet !== null) { + $_GET['id'] = $saveGet; + } else { + unset($_GET['id']); + } $configuration = $this->getPluginConfiguration($setup, 'rssdisplay'); $output = '';