[TASK] Doctrine: Introduce backend query context to exclude Placeholders 27/47827/3
authorMorton Jonuschat <m.jonuschat@mojocode.de>
Wed, 20 Apr 2016 18:37:57 +0000 (20:37 +0200)
committerWouter Wolters <typo3@wouterwolters.nl>
Wed, 27 Apr 2016 17:22:10 +0000 (19:22 +0200)
commite4d08f113ce86f37a25b29fdc04180a48d0f2feb
tree7e71e5a305d96790db92996f0a17c2075b8dec9c
parent7ec4d01e22ca7e7d6e64ccf8c7fe3e0970acb45c
[TASK] Doctrine: Introduce backend query context to exclude Placeholders

This patch adds a new query context BACKEND_NO_VERSIONING_PLACEHOLDERS
that de-selects versioning placeholders from other workspaces in the
same way that BackendUtility::versioningPlaceholdersClause() does. Usage
as follows:

$queryBuilder
  ->getQueryContext()
  ->setContext(QueryContextType::BACKEND_NO_VERSIONING_PLACEHOLDERS)
  ->setCurrentWorkspace(4);

Releases: master
Resolves: #75821
Change-Id: Iaa238f3da803c6d2dd23f0240cb2c409a39eec58
Reviewed-on: https://review.typo3.org/47827
Reviewed-by: Jonathan IROULIN <joniroutypo3@gmail.com>
Tested-by: Jonathan IROULIN <joniroutypo3@gmail.com>
Reviewed-by: Wouter Wolters <typo3@wouterwolters.nl>
Tested-by: Wouter Wolters <typo3@wouterwolters.nl>
typo3/sysext/core/Classes/Database/Query/QueryContextType.php
typo3/sysext/core/Classes/Database/Query/QueryRestrictionBuilder.php
typo3/sysext/core/Tests/Unit/Database/Query/QueryRestrictionBuilderTest.php