Commit 585c44d8 authored by Tymoteusz Motylewski's avatar Tymoteusz Motylewski Committed by Christian Kuhn
Browse files

[BUGFIX] Correctly check for permissions of a hidden field in context menu

Allow hidden field to not be an exclude field.
See other places in the core where check for check('non_exclude_fields')
is performed.

Resolves: #82785
Releases: master
Change-Id: Id6ab3c7b7dd0c727fe2458eb865c97433184aece
Reviewed-on: https://review.typo3.org/56343

Tested-by: default avatarTYPO3com <no-reply@typo3.com>
Reviewed-by: Anja Leichsenring's avatarAnja Leichsenring <aleichsenring@ab-softlab.de>
Tested-by: Anja Leichsenring's avatarAnja Leichsenring <aleichsenring@ab-softlab.de>
Reviewed-by: Christian Kuhn's avatarChristian Kuhn <lolli@schwarzbu.ch>
Tested-by: Christian Kuhn's avatarChristian Kuhn <lolli@schwarzbu.ch>
parent 030d961e
......@@ -607,8 +607,11 @@ class RecordProvider extends AbstractProvider
if (isset($GLOBALS['TCA'][$this->table]['ctrl']['enablecolumns']['disabled'])) {
$hiddenFieldName = $GLOBALS['TCA'][$this->table]['ctrl']['enablecolumns']['disabled'];
if (
$hiddenFieldName !== '' && !empty($GLOBALS['TCA'][$this->table]['columns'][$hiddenFieldName]['exclude'])
&& $this->backendUser->check('non_exclude_fields', $this->table . ':' . $hiddenFieldName)
$hiddenFieldName !== '' && !empty($GLOBALS['TCA'][$this->table]['columns'][$hiddenFieldName])
&& (
empty($GLOBALS['TCA'][$this->table]['columns'][$hiddenFieldName]['exclude'])
|| $this->backendUser->check('non_exclude_fields', $this->table . ':' . $hiddenFieldName)
)
) {
return (int)$this->record[$hiddenFieldName] === (int)$value;
}
......
Supports Markdown
0% or .
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment