Commit 9ce15af3 authored by Christian Kuhn's avatar Christian Kuhn Committed by Andreas Fernandez
Browse files

[BUGFIX] Avoid bogus title in new record controller

NewRecordController (+ icon in doc header of list
module) renders "Create a new page" on top. This
is not a link and looks misplaced.

It is a 'section header' for optional content that can
be enabled via pageTS.

mod.wizards.newRecord.pages.show.pageSelectPosition = 1
mod.wizards.newRecord.pages.show.pageInside = 1
mod.wizards.newRecord.pages.show.pageAfter = 1

When at least one of these are enabled, the header
makes sense, but should be avoided otherwise.

Resolves: #96505
Releases: main, 11.5
Change-Id: I6468cda44e719f268f6b59d7e61f240737da6f33
Reviewed-on: https://review.typo3.org/c/Packages/TYPO3.CMS/+/72962


Tested-by: Oliver Bartsch's avatarOliver Bartsch <bo@cedev.de>
Tested-by: core-ci's avatarcore-ci <typo3@b13.com>
Tested-by: Andreas Fernandez's avatarAndreas Fernandez <a.fernandez@scripting-base.de>
Reviewed-by: Oliver Bartsch's avatarOliver Bartsch <bo@cedev.de>
Reviewed-by: Andreas Fernandez's avatarAndreas Fernandez <a.fernandez@scripting-base.de>
parent 0e0524b5
......@@ -452,11 +452,13 @@ class NewRecordController
// Link to page-wizard
$newPageLinks[] = $this->renderPageSelectPositionLink();
}
$groupedLinksOnTop['pages'] = [
'title' => $lang->getLL('createNewPage'),
'icon' => 'actions-page-new',
'items' => $newPageLinks,
];
if (!empty($newPageLinks)) {
$groupedLinksOnTop['pages'] = [
'title' => $lang->getLL('createNewPage'),
'icon' => 'actions-page-new',
'items' => $newPageLinks,
];
}
break;
case 'tt_content':
if (!$this->newContentInto || !$this->isRecordCreationAllowedForTable($table) || !$this->isTableAllowedOnPage($table, $this->pageinfo)) {
......
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