#102090admPanel.override is not respected
Description
Hello. It seems that the configuration of admPanel.override in user tsconfig for non-admins are not respected. I tried several configurations like following. In Version 10 it worked properly. In Version 12 I can’t get it working like that. Can somebody verify? Thanks.
admPanel {
enable {
cache = 1
debug = 0
edit = 1
info = 0
preview = 1
publish = 0
tsdebug = 0
}
override {
preview = 1
preview.showFluidDebug = 0
}
hide = 0
}Reviews 4
Related issues 3
History 1113
-
Garvin Hicking commented and changed status
NewNeeds Feedback <span data-processor="relativetime" data-value="2025-04-02T09:18:23+00:00" > 04/02/25, 09:18 </span> -
Garvin Hicking changed Related to #106580 <span data-processor="relativetime" data-value="2025-04-16T18:09:51+00:00" > 04/16/25, 18:09 </span>
-
Oliver Schmidt commented <span data-processor="relativetime" data-value="2025-04-17T08:17:58+00:00" > 04/17/25, 08:17 </span>
Yeah, the admin panel is enabled and visible. Hide complete panels is working properly. But hiding only that single feature does not work. It’s like it is explaiend in your related bug.
-
Stefan Froemken commented <span data-processor="relativetime" data-value="2025-08-18T09:47:26+00:00" > 08/18/25, 09:47 </span>
In ConfigurationService of typo3/cms-adminpanel I found following lines:
$returnValue = $this->getMainConfiguration()['override.'][$identifier . '.'][$option] ?? $this->getBackendUser()->uc['AdminPanel'][$identifier . '_' . $option] ?? '';First you check the overrides, and if not set, you take over the value from BE_USER->uc. This is perfect to show/render the Checkbox partial for showFluidDebug in AdmPanel. Source code also tells us, that page will not be cached, if this specific option is activated:
if ($this->config['showFluidDebug']) { // forcibly unset fluid caching as it does not care about the tsfe based caching settings unset($GLOBALS['TYPO3_CONF_VARS']['SYS']['caching']['cacheConfigurations']['fluid_template']['frontend']); $request = $request->withAttribute('noCache', true); }Looks good until now. BUT: In ViewHelperResolver of typo3/cms-fluid I found following:
if (($GLOBALS['TYPO3_REQUEST'] ?? null) instanceof ServerRequestInterface && ApplicationType::fromRequest($GLOBALS['TYPO3_REQUEST'])->isFrontend() && $this->getBackendUser() instanceof BackendUserAuthentication ) { if ($this->getBackendUser()->uc['AdminPanel']['preview_showFluidDebug'] ?? false) { $this->namespaces['f'][] = 'TYPO3\\CMS\\Fluid\\ViewHelpers\\Debug'; } }Here, TYPO3 only checks for the activated Checkbox, but NOT for the UserTSconfig setting “override”. That way the complete “f” namespace will still be overwritten with Debug output. I don’t know, if no_cache will prevent the fluid VH compiler cache generation??
I would prefer adding the override option to ViewHelperResolver, too.
This will solve the problem for TYPO3 12 and 13. But how to solve the issue for TYPO3 11?
Stefan
-
Stefan Froemken commented <span data-processor="relativetime" data-value="2025-08-18T09:57:23+00:00" > 08/18/25, 09:57 </span>
Oh nice. ext_localconf.php
$GLOBALS['TYPO3_CONF_VARS']['BE']['defaultUC']['AdminPanel']['preview_showFluidDebug'] = false;and reset BE user settings.
But this will only help initially. But if user still activates that option and flush caches the debug is still there again. Damn
-
Stefan Froemken commented <span data-processor="relativetime" data-value="2025-08-18T10:45:38+00:00" > 08/18/25, 10:45 </span>
Storing of the user setting in Adminpanel happens in ConfigurationService:
// Settings $beUser->uc['AdminPanel'] = array_merge($existingConfiguration, $configurationToSave); unset($beUser->uc['AdminPanel']['action']); // Saving $beUser->writeUC();It will be written directly in uc column of be_users. No hook or EventListener available. Maybe core should check overrides here, too, to prevent storing this value, if deactivated via UserTSconfig.
Currently, I only see an option for TYPO3 11 to overwrite that value again with help of an Middleware which will be loaded just behind the BackendUserAuthenticator middleware.
<?php declare(strict_types=1); namespace JWeiland\SitePackage\Middleware; use Psr\Http\Message\ResponseInterface; use Psr\Http\Message\ServerRequestInterface; use Psr\Http\Server\MiddlewareInterface; use Psr\Http\Server\RequestHandlerInterface; use TYPO3\CMS\Core\Authentication\BackendUserAuthentication; class DeactivateFluidDebugMiddleware implements MiddlewareInterface { public function process(ServerRequestInterface $request, RequestHandlerInterface $handler): ResponseInterface { $beUser = $this->getBackendUser(); if ($beUser->uc['AdminPanel']['preview_showFluidDebug'] ?? false) { // Settings $beUser->uc['AdminPanel'] = array_merge($beUser->uc['AdminPanel'] ?? [], ['preview_showFluidDebug' => false]); // Saving $beUser->writeUC(); } return $handler->handle($request); } protected function getBackendUser(): BackendUserAuthentication { return $GLOBALS['BE_USER']; } } -
Stefan Froemken commented <span data-processor="relativetime" data-value="2025-08-18T12:02:14+00:00" > 08/18/25, 12:02 </span>
I just found:
if ( $module instanceof OnSubmitActorInterface && ( ($module instanceof ConfigurableInterface && $module->isEnabled()) || !($module instanceof ConfigurableInterface) ) ) { $module->onSubmit($configurationToSave, $request); }But no TYPO3 admin panel module implements OnSubmitActorInterface. Seems, that this implementation is ONLY for self-made modules. So, for TYPO3 11 and above you only have the middleware solution. See previous posting here.
-
Gerrit Code Review pushed patch set 1 for main to change 90722 status
Needs FeedbackUnder Review <span data-processor="relativetime" data-value="2025-09-18T21:19:09+00:00" > 09/18/25, 21:19 </span> -
Webadmin no-lastname-given changed Related to #101408 <span data-processor="relativetime" data-value="2025-12-08T08:01:59+00:00" > 12/08/25, 08:01 </span>
-
Gerrit Code Review pushed patch set 1 for 13.4 to change 92125 <span data-processor="relativetime" data-value="2025-12-15T16:32:46+00:00" > 12/15/25, 16:32 </span>
-
Stefan Froemken commented and changed status
Under ReviewResolved done0 %100 % <span data-processor="relativetime" data-value="2025-12-15T16:45:09+00:00" > 12/15/25, 16:45 </span>Applied in changeset commit:0467c7f1b0174daadfc88cac6cf8eb623e84ba77.
-
Simon Praetorius changed Related to #108518 <span data-processor="relativetime" data-value="2025-12-18T13:19:38+00:00" > 12/18/25, 13:19 </span>
-
Benni Mack changed status
ResolvedClosed <span data-processor="relativetime" data-value="2026-03-31T09:00:36+00:00" > 03/31/26, 09:00 </span>
Could you give more details?
The general admin panel works for your non-admin user, do I understand right? If you disable certain panels on the non-override level, that works for these users?
Are you sure the user ts config is actually loaded? How do you apply them?