From 21861b1b3eb184b110ce7086b5be294b8f8da24c Mon Sep 17 00:00:00 2001
From: Markus Goldbach <markus.goldbach@gmail.com>
Date: Mon, 26 Jun 2017 13:42:17 +0200
Subject: [PATCH] [BUGFIX] Ignore translations from other workspaces

Ignore translations of content elements (tt_content) which are created in
other workspace, so it is able to create a new/other translation in
another workspace even inside the live workspace

Change-Id: Ifef673b8677ae81f238068ed3a0bfdd1ca8e7932
Resolves: #81691
Releases: master, 8.7
Reviewed-on: https://review.typo3.org/53330
Tested-by: TYPO3com <no-reply@typo3.com>
Reviewed-by: Susanne Moog <susanne.moog@typo3.org>
Tested-by: Susanne Moog <susanne.moog@typo3.org>
Reviewed-by: Mathias Schreiber <mathias.schreiber@typo3.com>
Tested-by: Mathias Schreiber <mathias.schreiber@typo3.com>
Reviewed-by: Christian Kuhn <lolli@schwarzbu.ch>
Tested-by: Christian Kuhn <lolli@schwarzbu.ch>
---
 typo3/sysext/backend/Classes/View/PageLayoutView.php | 3 ++-
 1 file changed, 2 insertions(+), 1 deletion(-)

diff --git a/typo3/sysext/backend/Classes/View/PageLayoutView.php b/typo3/sysext/backend/Classes/View/PageLayoutView.php
index c43f561523ac..d17cf10cdf84 100644
--- a/typo3/sysext/backend/Classes/View/PageLayoutView.php
+++ b/typo3/sysext/backend/Classes/View/PageLayoutView.php
@@ -2266,7 +2266,8 @@ class PageLayoutView implements LoggerAwareInterface
                 ->getQueryBuilderForTable('tt_content');
             $queryBuilder->getRestrictions()
                 ->removeAll()
-                ->add(GeneralUtility::makeInstance(DeletedRestriction::class));
+                ->add(GeneralUtility::makeInstance(DeletedRestriction::class))
+                ->add(GeneralUtility::makeInstance(BackendWorkspaceRestriction::class, null, false));
             $queryBuilder
                 ->select('*')
                 ->from('tt_content')
-- 
GitLab