Project

General

Profile

Actions

Bug #82785

closed

Disable/Enable page missing from ContextMenu

Added by Robert Vock about 7 years ago. Updated about 6 years ago.

Status:
Closed
Priority:
Should have
Assignee:
-
Category:
Backend User Interface
Target version:
-
Start date:
2017-10-17
Due date:
% Done:

100%

Estimated time:
TYPO3 Version:
8
PHP Version:
7.0
Tags:
Complexity:
Is Regression:
Sprint Focus:

Description

When you disable the exclude-configuration for the hidden field of pages, the Disable/Enable entry in the PageTree ContextMenu is missing.

All my editors should have access to the hidden-field of pages. That's why I added the following configuration in TCA/Overrides/pages.php

unset($GLOBALS['TCA']['pages']['columns']['hidden']['exclude']);

I prefer unsetting exclude fields in TCA over allowing exclude-fields in the user group (if all groups should have access to a field), because I can check in these changes in source-control and the list of exclude-fields in backend user groups gets shorter and clearer.

But when the exclude-setting for hidden is removed, the following check will always return false:
RecordProvider.php#L583

I believe the fix would be to change this if-clause to

if (
    $hiddenFieldName !== '' && (!isset($GLOBALS['TCA'][$this->table]['columns'][$hiddenFieldName]['exclude'])
    || $this->backendUser->check('non_exclude_fields', $this->table . ':' . $hiddenFieldName))
) {


Files

ContextMenu.png (16.4 KB) ContextMenu.png Robert Vock, 2017-10-17 15:58
Actions #1

Updated by Gerrit Code Review over 6 years 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/56343

Actions #2

Updated by Tymoteusz Motylewski over 6 years ago

  • Status changed from Under Review to Resolved
  • % Done changed from 0 to 100
Actions #3

Updated by Benni Mack about 6 years ago

  • Status changed from Resolved to Closed
Actions

Also available in: Atom PDF