Project

General

Profile

Actions

Bug #106356

open

Workspace Preview for restricted pages not working

Added by Roman Schilter 13 days ago. Updated 13 days ago.

Status:
New
Priority:
Should have
Assignee:
-
Category:
Workspaces
Target version:
-
Start date:
2025-03-11
Due date:
% Done:

0%

Estimated time:
TYPO3 Version:
12
PHP Version:
8.1
Tags:
Complexity:
Is Regression:
Sprint Focus:

Description

Trying to preview a (fe-group-)restricted page in a workspace will always show the root page instead of the selected page.

Steps to reproduce:
1. Create a page and restrict it to a fe-group
2. Switch to a non-LIVE workspace
3. Click "View webpage" for the previously restricted page

Expected Result:
The restricted page is displayed.

Actual Result:
The root-page of the current site is displayed.

Actions #1

Updated by Roman Schilter 13 days ago

The PreviewController generates the uri using the PageRouter, which in turn uses the PageRepository to fetch the page (see https://github.com/typo3/typo3/blob/f6b1178d4e8a25704223c3ebd1f0bf9e0f1faddb/typo3/sysext/core/Classes/Routing/PageRouter.php#L274).
This page is empty in this case.

The reason is because in the PageRepository in the function versionOL the access is checked again.
It works when the parameter $bypassEnableFieldsCheck for versionOL is set to true.

Actions

Also available in: Atom PDF