From: Alexander Ebert Date: Thu, 3 Jan 2013 17:45:08 +0000 (+0100) Subject: Added menuItemController for *Menu-PIPs X-Git-Tag: 2.0.0_Beta_1~584^2~1^2~5 X-Git-Url: https://git.stricted.de/?a=commitdiff_plain;h=ab9f8211666c0a890f4fecc1ff040cae072d3053;p=GitHub%2FWoltLab%2FWCF.git Added menuItemController for *Menu-PIPs --- diff --git a/wcfsetup/install/files/lib/system/package/plugin/ACPMenuPackageInstallationPlugin.class.php b/wcfsetup/install/files/lib/system/package/plugin/ACPMenuPackageInstallationPlugin.class.php index 23c677d03c..f10f11ede6 100644 --- a/wcfsetup/install/files/lib/system/package/plugin/ACPMenuPackageInstallationPlugin.class.php +++ b/wcfsetup/install/files/lib/system/package/plugin/ACPMenuPackageInstallationPlugin.class.php @@ -5,7 +5,7 @@ namespace wcf\system\package\plugin; * Installs, updates and deletes ACP menu items. * * @author Alexander Ebert - * @copyright 2001-2012 WoltLab GmbH + * @copyright 2001-2013 WoltLab GmbH * @license GNU Lesser General Public License * @package com.woltlab.wcf * @subpackage system.package.plugin @@ -16,16 +16,4 @@ class ACPMenuPackageInstallationPlugin extends AbstractMenuPackageInstallationPl * @see wcf\system\package\plugin\AbstractXMLPackageInstallationPlugin::$className */ public $className = 'wcf\data\acp\menu\item\ACPMenuItemEditor'; - - /** - * @see wcf\system\package\plugin\AbstractXMLPackageInstallationPlugin::prepareImport() - */ - protected function prepareImport(array $data) { - $result = parent::prepareImport($data); - - // controller - $result['menuItemController'] = isset($data['elements']['controller']) ? $data['elements']['controller'] : ''; - - return $result; - } } diff --git a/wcfsetup/install/files/lib/system/package/plugin/AbstractMenuPackageInstallationPlugin.class.php b/wcfsetup/install/files/lib/system/package/plugin/AbstractMenuPackageInstallationPlugin.class.php index fa785a4d7f..99dbf0a7e0 100644 --- a/wcfsetup/install/files/lib/system/package/plugin/AbstractMenuPackageInstallationPlugin.class.php +++ b/wcfsetup/install/files/lib/system/package/plugin/AbstractMenuPackageInstallationPlugin.class.php @@ -42,6 +42,7 @@ abstract class AbstractMenuPackageInstallationPlugin extends AbstractXMLPackageI // merge values and default values return array( 'menuItem' => $data['attributes']['name'], + 'menuItemController' => isset($data['elements']['controller']) ? $data['elements']['controller'] : '', 'menuItemLink' => (isset($data['elements']['link'])) ? $data['elements']['link'] : '', 'options' => (isset($data['elements']['options'])) ? $data['elements']['options'] : '', 'parentMenuItem' => (isset($data['elements']['parent'])) ? $data['elements']['parent'] : '', diff --git a/wcfsetup/install/files/lib/system/package/plugin/PageMenuPackageInstallationPlugin.class.php b/wcfsetup/install/files/lib/system/package/plugin/PageMenuPackageInstallationPlugin.class.php index a78b77ff6d..f3b9cac00e 100644 --- a/wcfsetup/install/files/lib/system/package/plugin/PageMenuPackageInstallationPlugin.class.php +++ b/wcfsetup/install/files/lib/system/package/plugin/PageMenuPackageInstallationPlugin.class.php @@ -28,9 +28,6 @@ class PageMenuPackageInstallationPlugin extends AbstractMenuPackageInstallationP // position $result['menuPosition'] = (!empty($data['elements']['position']) && $data['elements']['position'] == 'footer') ? 'footer' : 'header'; - // controller - $result['menuItemController'] = (isset($data['elements']['controller'])) ? $data['elements']['controller'] : ''; - // class name if (!empty($data['elements']['classname'])) { $result['className'] = $data['elements']['classname'];