[BUGFIX] Ignore translations from other workspaces 66/54866/2
authorMarkus Goldbach <markus.goldbach@gmail.com>
Mon, 26 Jun 2017 11:42:17 +0000 (13:42 +0200)
committerChristian Kuhn <lolli@schwarzbu.ch>
Wed, 29 Nov 2017 16:05:46 +0000 (17:05 +0100)
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/54866
Tested-by: TYPO3com <no-reply@typo3.com>
Reviewed-by: Christian Kuhn <lolli@schwarzbu.ch>
Tested-by: Christian Kuhn <lolli@schwarzbu.ch>
typo3/sysext/backend/Classes/View/PageLayoutView.php

index 07e012f..ec84cf4 100644 (file)
@@ -1928,7 +1928,8 @@ class PageLayoutView extends \TYPO3\CMS\Recordlist\RecordList\AbstractDatabaseRe
                 ->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')