[FEATURE] Add "Hide in menus" checkbox in crpages wizard 31/23531/2
authoreric.chavaillaz <eric@hemmer.ch>
Sun, 1 Sep 2013 13:52:21 +0000 (15:52 +0200)
committerWouter Wolters <typo3@wouterwolters.nl>
Sun, 1 Sep 2013 15:43:19 +0000 (17:43 +0200)
Add a checkbox to directly hide pages in the crpages wizard
of the "functions" module.

Resolves: #51017
Releases: 6.2
Change-Id: Iff6abfe862bd0a0f0e2e8ff3064c4a4f6ea001d9
Reviewed-on: https://review.typo3.org/23531
Reviewed-by: Tomita Militaru
Tested-by: Tomita Militaru
Reviewed-by: Wouter Wolters
Tested-by: Wouter Wolters
typo3/sysext/wizard_crpages/Classes/Controller/CreatePagesWizardModuleFunctionController.php
typo3/sysext/wizard_crpages/locallang.xlf

index c3a6ab1..c71f8f8 100644 (file)
@@ -115,6 +115,7 @@ class CreatePagesWizardModuleFunctionController extends \TYPO3\CMS\Backend\Modul
                                                unset($data['pages'][$identifier]);
                                        } else {
                                                $data['pages'][$identifier]['hidden'] = GeneralUtility::_GP('hidePages') ? 1 : 0;
+                                               $data['pages'][$identifier]['nav_hide'] = GeneralUtility::_GP('hidePagesInMenus') ? 1 : 0;
                                                if ($firstRecord) {
                                                        $firstRecord = FALSE;
                                                        $data['pages'][$identifier]['pid'] = $thePid;
@@ -159,7 +160,8 @@ class CreatePagesWizardModuleFunctionController extends \TYPO3\CMS\Backend\Modul
                                }
                                $theCode .= '<h4>' . $GLOBALS['LANG']->getLL('wiz_newPages') . ':</h4>' . '<div id="formFieldContainer">' . implode('', $lines) . '</div>' . '<br class="clearLeft" />' . '<input type="button" id="createNewFormFields" value="' . $GLOBALS['LANG']->getLL('wiz_newPages_addMoreLines') . '" />' . '<br /><br />
                                <input type="checkbox" name="createInListEnd" id="createInListEnd" value="1" /> <label for="createInListEnd">' . $GLOBALS['LANG']->getLL('wiz_newPages_listEnd') . '</label><br />
-                               <input type="checkbox" name="hidePages" id="hidePages" value="1" /> <label for="hidePages">' . $GLOBALS['LANG']->getLL('wiz_newPages_hidePages') . '</label><br /><br />
+                               <input type="checkbox" name="hidePages" id="hidePages" value="1" /> <label for="hidePages">' . $GLOBALS['LANG']->getLL('wiz_newPages_hidePages') . '</label><br />
+                               <input type="checkbox" name="hidePagesInMenus" id="hidePagesInMenus" value="1" /> <label for="hidePagesInMenus">' . $GLOBALS['LANG']->getLL('wiz_newPages_hidePagesInMenus') . '</label><br /><br />
                                <input type="submit" name="create" value="' . $GLOBALS['LANG']->getLL('wiz_newPages_lCreate') . '" />&nbsp;<input type="reset" value="' . $GLOBALS['LANG']->getLL('wiz_newPages_lReset') . '" /><br />';
                                // Add ExtJS inline code
                                $extCode = '
index 44bdf5a..c2d053d 100644 (file)
@@ -30,6 +30,9 @@
                        <trans-unit id="wiz_newPages_hidePages" xml:space="preserve">
                                <source>Hide new pages</source>
                        </trans-unit>
+                       <trans-unit id="wiz_newPages_hidePagesInMenus" xml:space="preserve">
+                           <source>Hide new pages in menus</source>
+                       </trans-unit>
                        <trans-unit id="wiz_newPages_lCreate_msg1" xml:space="preserve">
                                <source>You're about to create many new pages. Are you sure you want to continue?</source>
                        </trans-unit>