From 415be95750f42d90b1a6a5338a28be9c0c5fd5ff Mon Sep 17 00:00:00 2001 From: Stefan Scheu Date: Thu, 14 Dec 2023 09:01:18 +0100 Subject: [PATCH] fix: fixed setting target group using inherited editables after change from pimcore --- bundles/CoreBundle/EventListener/Frontend/ElementListener.php | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/bundles/CoreBundle/EventListener/Frontend/ElementListener.php b/bundles/CoreBundle/EventListener/Frontend/ElementListener.php index e5470e11e15..3afd0abcca3 100644 --- a/bundles/CoreBundle/EventListener/Frontend/ElementListener.php +++ b/bundles/CoreBundle/EventListener/Frontend/ElementListener.php @@ -172,8 +172,10 @@ protected function applyTargetGroups(Request $request, Document $document) // reset because of preview and editmode (saved in session) $document->setUseTargetGroup(null); + $originalSetting = Document\PageSnippet::getGetInheritedValues(); + Document\PageSnippet::setGetInheritedValues(true); $this->targetingConfigurator->configureTargetGroup($document); - + Document\PageSnippet::setGetInheritedValues($originalSetting); if ($document->getUseTargetGroup()) { $this->logger->info('Setting target group to {targetGroup} for document {document}', [ 'targetGroup' => $document->getUseTargetGroup(),