[TASK] Rename QueryContextType::NONE to QueryContextType::UNRESTRICTED 59/47759/6
authorMorton Jonuschat <m.jonuschat@mojocode.de>
Mon, 18 Apr 2016 17:52:03 +0000 (19:52 +0200)
committerSusanne Moog <typo3@susannemoog.de>
Tue, 19 Apr 2016 08:17:53 +0000 (10:17 +0200)
commitd4925ddbb43066a8752c791314d6d4fd0134d62d
treed0b0e7abfa79efcf08c9686a491b4898d85b0284
parent73248e33710826955b01b79d6df563fa92825262
[TASK] Rename QueryContextType::NONE to QueryContextType::UNRESTRICTED

This name change transports the intent of the query context better and
makes it more intuitive to use.

Instead of explicitly disabling all enable fields and the deleted flag
using the following code:

$queryBuilder->getQueryContext()
    ->setIgnoreEnableFields(true)
    ->setIncludeDeleted(true);

the more descriptive predefined context can be used:

$queryBuilder->getQueryContext()->setContext('unrestricted')

Releases: master
Resolves: #75751
Change-Id: I4d38a328c2b6707a32f26022b4abfc48e945c0ed
Reviewed-on: https://review.typo3.org/47759
Reviewed-by: Andreas Fernandez <typo3@scripting-base.de>
Reviewed-by: Georg Ringer <georg.ringer@gmail.com>
Tested-by: Georg Ringer <georg.ringer@gmail.com>
Reviewed-by: Susanne Moog <typo3@susannemoog.de>
Tested-by: Susanne Moog <typo3@susannemoog.de>
typo3/sysext/backend/Classes/History/RecordHistory.php
typo3/sysext/core/Classes/Database/Query/QueryContext.php
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
typo3/sysext/recycler/Classes/Domain/Model/Tables.php