isSitePlugin() && !Validation::isSiteAdmin()) return array(); if ($this->getEnabled()) { $verbs[] = array('disable', __('common.disable')); } else { $verbs[] = array('enable', __('common.enable')); } return $verbs; } /** * @see PKPPlugin::manage() */ function manage($verb, $args, &$message, &$messageParams) { if ($verb != 'enable' && !$this->getEnabled()) fatalError('Invalid management action on disabled plug-in!'); switch ($verb) { case 'enable': $this->setEnabled(true); $message = NOTIFICATION_TYPE_PLUGIN_ENABLED; $messageParams = array('pluginName' => $this->getDisplayName()); return false; case 'disable': $this->setEnabled(false); $message = NOTIFICATION_TYPE_PLUGIN_DISABLED; $messageParams = array('pluginName' => $this->getDisplayName()); return false; } return true; } } ?>