Bug #85260

Can not create new page via context menu on root page as editor

Added by Christoph Lehmann 6 months ago. Updated 5 months ago.

Status:
Under Review
Priority:
Should have
Assignee:
-
Category:
Backend User Interface
Target version:
-
Start date:
2018-06-14
Due date:
% Done:

0%

TYPO3 Version:
8
PHP Version:
Tags:
Complexity:
Is Regression:
Sprint Focus:

Description

As an editor i have all permissions on a page which is marked as root page. I can not create a new page via context menu (right klick), but it works via drag&drop.

Bildschirmfoto 2018-06-14 um 13.19.50.png View (14.6 KB) Christoph Lehmann, 2018-06-14 13:25

Bildschirmfoto 2018-06-14 um 13.25.38.png View (6.5 KB) Christoph Lehmann, 2018-06-14 13:27


Related issues

Related to TYPO3 Core - Bug #81405: New pages are places at same level instead of under, when using the ContextMenu. New 2017-06-01

History

#1 Updated by Guido Schmechel 5 months ago

Can reproduce it with 9.4.dev

master\typo3\sysext\backend\Classes\Form\FormDataProvider\DatabaseUserPermissionCheck.php function addData()
if (is_array($result['parentPageRow']))

$result['parentPageRow'] is null if editor creates a page at root. Admin user has a separate check and returns simple true

master\typo3\sysext\backend\Classes\Form\FormDataProvider\DatabaseParentPageRow.php
This class should return correctly null if root level is accessed.

Maybe its okay to use $result['neighborRow'] if $result['parentPageRow'] is null.

After that the saving throws this exception:
1: Attempt to insert a record on page '[root-level]' (0) from table 'pages' without permissions. Or non-existing page.

master\typo3\sysext\core\Classes\DataHandling\DataHandler.php
checkRecordInsertAccess() get a negative value via resolveSortingAndPidForNewRecord()

So a simple abs() does the trick

#2 Updated by Gerrit Code Review 5 months ago

  • Status changed from New to Under Review

Patch set 1 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/57497

#3 Updated by Gerrit Code Review 5 months ago

Patch set 2 for branch master of project Packages/TYPO3.CMS has been pushed to the review server.
It is available at https://review.typo3.org/57497

#4 Updated by Riccardo De Contardi 5 months ago

Is this the same issue? #81405

#5 Updated by Riccardo De Contardi 5 months ago

  • Related to Bug #81405: New pages are places at same level instead of under, when using the ContextMenu. added

Also available in: Atom PDF