[TASK] Followup: Remove conf.php from ext:tstemplate 41/35141/4
authorStefan Neufeind <typo3.neufeind@speedpartner.de>
Sun, 7 Dec 2014 22:45:02 +0000 (23:45 +0100)
committerWouter Wolters <typo3@wouterwolters.nl>
Fri, 12 Dec 2014 18:28:47 +0000 (19:28 +0100)
Get rid of the $moduleName again, use $MCONF['name'] for now.

Change-Id: I1ccabc2dddd5814902138f0889c294e662d052a5
Resolves: #63583
Releases: master
Reviewed-on: http://review.typo3.org/35141
Reviewed-by: Markus Klein <klein.t3@reelworx.at>
Tested-by: Markus Klein <klein.t3@reelworx.at>
Reviewed-by: Wouter Wolters <typo3@wouterwolters.nl>
Tested-by: Wouter Wolters <typo3@wouterwolters.nl>
typo3/sysext/tstemplate/Classes/Controller/TypoScriptTemplateConstantEditorModuleFunctionController.php
typo3/sysext/tstemplate/Classes/Controller/TypoScriptTemplateModuleController.php
typo3/sysext/tstemplate/Classes/Controller/TypoScriptTemplateObjectBrowserModuleFunctionController.php

index 52a6b96..67094b1 100644 (file)
@@ -121,7 +121,7 @@ class TypoScriptTemplateConstantEditorModuleFunctionController extends \TYPO3\CM
                        }
                        // Resetting the menu (start). I wonder if this in any way is a violation of the menu-system. Haven't checked. But need to do it here, because the menu is dependent on the categories available.
                        $this->pObj->MOD_MENU['constant_editor_cat'] = $tmpl->ext_getCategoryLabelArray();
-                       $this->pObj->MOD_SETTINGS = \TYPO3\CMS\Backend\Utility\BackendUtility::getModuleData($this->pObj->MOD_MENU, \TYPO3\CMS\Core\Utility\GeneralUtility::_GP('SET'), $this->pObj->moduleName);
+                       $this->pObj->MOD_SETTINGS = \TYPO3\CMS\Backend\Utility\BackendUtility::getModuleData($this->pObj->MOD_MENU, \TYPO3\CMS\Core\Utility\GeneralUtility::_GP('SET'), $this->pObj->MCONF['name']);
                        // Resetting the menu (stop)
                        $content = \TYPO3\CMS\Backend\Utility\IconUtility::getSpriteIconForRecord('sys_template', $tplRow) . '<strong>' . $this->pObj->linkWrapTemplateTitle($tplRow['title'], 'constants') . '</strong>' . htmlspecialchars((trim($tplRow['sitetitle']) ? ' (' . $tplRow['sitetitle'] . ')' : ''));
                        $theOutput .= $this->pObj->doc->section($GLOBALS['LANG']->getLL('editConstants', TRUE), $content, FALSE, TRUE);
index d5eafe5..42536c8 100644 (file)
@@ -82,13 +82,14 @@ class TypoScriptTemplateModuleController extends \TYPO3\CMS\Backend\Module\BaseS
         *
         * @var string
         */
-       public $moduleName = 'web_ts';
+       protected $moduleName = 'web_ts';
 
        /**
         * Constructor
         */
        public function __construct() {
                $GLOBALS['LANG']->includeLLFile('EXT:tstemplate/ts/locallang.xlf');
+
                $this->MCONF = array(
                        'name' => $this->moduleName
                );
index 58d6e53..748a0ff 100644 (file)
@@ -75,7 +75,7 @@ class TypoScriptTemplateObjectBrowserModuleFunctionController extends \TYPO3\CMS
                                } else {
                                        unset($this->pObj->MOD_SETTINGS['ts_browser_TLKeys_' . $bType][key($addKey)]);
                                }
-                               $GLOBALS['BE_USER']->pushModuleData($this->pObj->moduleName, $this->pObj->MOD_SETTINGS);
+                               $GLOBALS['BE_USER']->pushModuleData($this->pObj->MCONF['name'], $this->pObj->MOD_SETTINGS);
                        }
                        if (count($this->pObj->MOD_SETTINGS['ts_browser_TLKeys_' . $bType])) {
                                $modMenu['ts_browser_toplevel_' . $bType]['-'] = '---';
@@ -272,7 +272,7 @@ class TypoScriptTemplateObjectBrowserModuleFunctionController extends \TYPO3\CMS
                        $update = 1;
                }
                if ($update) {
-                       $GLOBALS['BE_USER']->pushModuleData($this->pObj->moduleName, $this->pObj->MOD_SETTINGS);
+                       $GLOBALS['BE_USER']->pushModuleData($this->pObj->MCONF['name'], $this->pObj->MOD_SETTINGS);
                }
                $tmpl->matchAlternative = $this->pObj->MOD_SETTINGS['tsbrowser_conditions'];
                $tmpl->matchAlternative[] = 'dummydummydummydummydummydummydummydummydummydummydummy';