function handler() { return eZCollaborationItemHandler::instantiate($this->attribute('type_identifier')); }
<?php /** * @copyright Copyright (C) 1999-2012 eZ Systems AS. All rights reserved. * @license http://www.gnu.org/licenses/gpl-2.0.txt GNU General Public License v2 * @version //autogentag// * @package kernel */ $Module = $Params['Module']; $http = eZHTTPTool::instance(); if ( $Module->isCurrentAction( 'Custom' ) ) { $typeIdentifier = $Module->actionParameter( 'TypeIdentifer' ); $itemID = $Module->actionParameter( 'ItemID' ); $collaborationItem = eZCollaborationItem::fetch( $itemID ); $handler = eZCollaborationItemHandler::instantiate( $typeIdentifier ); return $handler->handleCustomAction( $Module, $collaborationItem ); } $Result = array(); $Result['content'] = false; $Result['path'] = array( array( 'url' => false, ezpI18n::tr( 'kernel/collaboration', 'Collaboration custom action' ) ) ); ?>
static function fetchList() { $list =& $GLOBALS['eZCollaborationList']; if (isset($list)) { return $list; } $list = array(); $activeHandlers = eZCollaborationItemHandler::activeHandlers(); $repositories = eZCollaborationItemHandler::handlerRepositories(); foreach ($activeHandlers as $handler) { $handlerInstance = eZCollaborationItemHandler::instantiate($handler, $repositories); if ($handlerInstance !== null) { $list[] = $handlerInstance; } } return $list; }
function collaborationHandlers() { return eZCollaborationItemHandler::fetchList(); }
function __construct() { parent::__construct('ezapprove', ezpI18n::tr('kernel/classes', 'Approval'), array('use-messages' => true, 'notification-types' => true, 'notification-collection-handling' => eZCollaborationItemHandler::NOTIFICATION_COLLECTION_PER_PARTICIPATION_ROLE)); }