Separate CookieList template rendering from consent modal design
Hi, thank you for allowing to configure the Fluid templates! We encountered a new problem when setting a custom path for the Cookie list template:
plugin.tx_sgcookieoptin {
settings {
templates.CookieList.full = EXT:sitepackage/Resources/Private/Templates/Extensions/sg_cookie_optin/CookieList/Full/
}
}
The custom path will currently only be used if template_selection
in the consent record is set to "full".
This connects the rendering of the cookie list with the styling of the consent modal.
Is the following condition in CookieListController
and LegacyOptinController
still necessary or a remnant of the former rendering?
if ($optin['template_selection'] === 1) {
$templatePath = $this->settings['templates']['CookieList']['full'];
$templateRootPaths = $this->view->getRenderingContext()->getTemplatePaths()->getTemplateRootPaths();
$templateRootPaths[0] = $templatePath;
$this->view->setTemplateRootPaths($templateRootPaths);
}