Actions
Bug #105889
openProblem with ContentObjectRenderer select and pidInList = root
Status:
New
Priority:
Should have
Assignee:
-
Category:
Frontend
Target version:
-
Start date:
2025-01-06
Due date:
% Done:
0%
Estimated time:
TYPO3 Version:
12
PHP Version:
8.2
Tags:
Complexity:
Is Regression:
Sprint Focus:
Description
Hello,
I am using this TypoScript from the documentation https://docs.typo3.org/permalink/t3tsref:select-pidinlist:
10 = CONTENT 10 { table = sys_category select { pidInList = root,-1 selectFields = sys_category.* join = sys_category_record_mm ON sys_category_record_mm.uid_local = sys_category.uid where.data = field:_ORIG_uid // field:uid where.intval = 1 where.wrap = sys_category_record_mm.uid_foreign=| orderBy = sys_category_record_mm.sorting_foreign languageField = 0 # disable translation handling of sys_category } }
but it doesn't work.
The problem seems to be in typo3/cms-frontend/Classes/ContentObject/ContentObjectRenderer.php. In the method getQuery(), starting on line 5138, the program calls in line 5207 the method $this->getTypoScriptFrontendController()->sys_page->getPageIdsRecursive(). This method transforms with
$pageIds = array_map('intval', $pageIds);
all entries in pidInList in integers.
Back in ContentObjectRenderer.php on on line 5217 the programm calls $this->getQueryConstraints(), which checks on line 5463 if pidInList contains 'root' but that got already transformed into the integer 0. So the example from the documentation doesn't work.
No data to display
Actions