[BUGFIX] Correct show configuration in newContentElement wizard 83/49883/2
authorNicole Cordes <typo3@cordes.co>
Wed, 7 Sep 2016 14:01:54 +0000 (16:01 +0200)
committerNicole Cordes <typo3@cordes.co>
Fri, 16 Sep 2016 10:35:11 +0000 (12:35 +0200)
All elements should be shown if the asterisk is part of the show
configuration. Due to different configuration possibilities it can happen
that the asterisk is not the only value of this configuration.

Resolves: #77877
Releases: master, 7.6, 6.2
Change-Id: I5439f76ec40788cdaed14012e7b83b18e2b56d18
Reviewed-on: https://review.typo3.org/49883
Tested-by: TYPO3com <no-reply@typo3.com>
Reviewed-by: Markus Sommer <markussom@posteo.de>
Tested-by: Markus Sommer <markussom@posteo.de>
Reviewed-by: Nicole Cordes <typo3@cordes.co>
Tested-by: Nicole Cordes <typo3@cordes.co>
typo3/sysext/backend/Classes/Controller/ContentElement/NewContentElementController.php

index 41b89bb..a3ce592 100644 (file)
@@ -401,7 +401,7 @@ class NewContentElementController extends AbstractModule
                 foreach ($wizards as $groupKey => $wizardGroup) {
                     $groupKey = rtrim($groupKey, '.');
                     $showItems = GeneralUtility::trimExplode(',', $wizardGroup['show'], true);
-                    $showAll = $wizardGroup['show'] === '*';
+                    $showAll = in_array('*', $showItems, true);
                     $groupItems = [];
                     if (is_array($appendWizards[$groupKey . '.']['elements.'])) {
                         $wizardElements = array_merge((array)$wizardGroup['elements.'], $appendWizards[$groupKey . '.']['elements.']);