Actions
Bug #103573
openUsing site configuration in TCA not working for new page
Status:
Under Review
Priority:
Should have
Assignee:
-
Category:
Backend User Interface
Target version:
-
Start date:
2024-04-09
Due date:
% Done:
0%
Estimated time:
TYPO3 Version:
12
PHP Version:
8.2
Tags:
Complexity:
Is Regression:
Sprint Focus:
Description
“###SITE:mySetting.categoryPid###” does not work when you are in the form to create a new page.
The TCA for pages has therefore been extended and exactly this configuration has been implemented.
// ...
'fieldConfiguration' => [
'foreign_table_where' => ' AND ({#sys_category}.uid = ###SITE:rootPageId### OR {#sys_category}.pid = ###SITE:mySetting.categoryPid###) ORDER BY sys_category.title ASC',
],
// ...
As no site object exists at this point, it is from the “NullSite” object. This is why the parsing in AbstractitemProvider->parseSiteConfiguration() exits at this point and produces an error, because it doesn’t parse the statement. Since no site exists, the site configuration cannot be read.
Therefore this behavior only exists when a new page is created. An existing page works perfectly.
Same behavior exists in V12 and V11.
Files
Actions