Skip to content
Snippets Groups Projects
Commit 3f459e78 authored by Ernesto Baschny's avatar Ernesto Baschny
Browse files

[BUGFIX] Page tree filter couldn't filter for id or title anymore

Bug was introduced by #54265, one "(int)" was forgotten.

Releases: 6.2
Resolves: #55642
Change-Id: Ie56b36be9d2f11b46687c2966d84e49f301ffede
Reviewed-on: https://review.typo3.org/27317
Reviewed-by: Daniel Siepmann
Tested-by: Daniel Siepmann
Reviewed-by: Stefan Froemken
Tested-by: Stefan Froemken
Reviewed-by: Ernesto Baschny
Tested-by: Ernesto Baschny
parent 373a90b8
No related merge requests found
......@@ -270,7 +270,7 @@ class DataProvider extends \TYPO3\CMS\Backend\Tree\AbstractTreeDataProvider {
) {
continue;
}
if ($rootlineElement['pid'] === $nodeId
if ((int)$rootlineElement['pid'] === $nodeId
|| $rootlineElement['uid'] === $nodeId
|| ($rootlineElement['uid'] === $isInWebMount
&& in_array($rootlineElement['uid'], $mountPoints, TRUE))
......@@ -281,7 +281,7 @@ class DataProvider extends \TYPO3\CMS\Backend\Tree\AbstractTreeDataProvider {
continue;
}
$rootlineElement = Commands::getNodeRecord($rootlineElement['uid'], FALSE);
$ident = (int)$rootlineElement['sorting'] . $rootlineElement['uid'];
$ident = (int)$rootlineElement['sorting'] . (int)$rootlineElement['uid'];
if ($reference && $reference->offsetExists($ident)) {
/** @var $refNode \TYPO3\CMS\Backend\Tree\Pagetree\PagetreeNode */
$refNode = $reference->offsetGet($ident);
......@@ -295,7 +295,7 @@ class DataProvider extends \TYPO3\CMS\Backend\Tree\AbstractTreeDataProvider {
} else {
$refNode = Commands::getNewNode($rootlineElement, $mountPoint);
$replacement = '<span class="typo3-pagetree-filteringTree-highlight">$1</span>';
if ($isNumericSearchFilter && $rootlineElement['uid'] === (int)$searchFilter) {
if ($isNumericSearchFilter && (int)$rootlineElement['uid'] === (int)$searchFilter) {
$text = str_replace('$1', $refNode->getText(), $replacement);
} else {
$text = preg_replace('/(' . $searchFilterQuoted . ')/i', $replacement, $refNode->getText());
......
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment