Actions
Bug #97220
closedExtbase is not fully workspace aware in backend context
Status:
Closed
Priority:
Should have
Assignee:
-
Category:
Extbase
Target version:
-
Start date:
2022-03-21
Due date:
% Done:
0%
Estimated time:
TYPO3 Version:
10
PHP Version:
Tags:
Complexity:
Is Regression:
Sprint Focus:
Stabilization Sprint
Description
When data is fetched from an extbase repository in backend context, it is not respected that the query should also respect the current workspace the backend user is working on.
Prerequisites:
- Extbase repository (ignore storage page) and a domain model
How to reproduce:
- Create a new record for the domain model
- Use the repository in FE context and use findAll()
- One record will be returned -> this is correct
- Switch to a workspace
- Create another record for the domain model
- Use the repository in FE context and use findAll()
- Two record will be returned -> this is correct
- Switch to live workspace
- Use the repository in FE context and use findAll()
- Two record will be returned -> this is not correct since the hew record created in the workspace is not published
The function getBackendConstraintStatement
should add constraints for t3ver_state
and t3ver_wsid
constraints (see https://github.com/TYPO3/typo3/blob/main/typo3/sysext/extbase/Classes/Persistence/Generic/Storage/Typo3DbQueryParser.php#L738) depending on the workspace the user is working in.
Actions