Source for file actions.php
Documentation is available at actions.php
* List of all currently available actions
* @author Stuart Prescott
* @copyright Copyright Stuart Prescott
* @license http://opensource.org/licenses/gpl-license.php GNU Public License
* path (bumblebee root)/inc/actions/actions.php
/** Load ancillary functions */
require_once 'inc/typeinfo.php';
require_once 'inc/permissions.php';
/** @var string name of the action in action= URL */
/** @var string title for the html page */
/** @var string name of the action for the menu */
/** @var string name of the Action* class that should be instantiated */
/** @var boolean include the entry on the menu */
/** @var integer permissions required for this action */
/** @var integer menu order number (lowest numbers at top of menu) */
/** @var integer name of the action that should follow next (defaults to $this->name) */
* Create a new ActionData object
* @param string $class name of the class to be instantiated
* @param string $file name of the php file to be included
* @param integer $permissions from permissions.php (default: BBROLE_NONE)
* @param integer $menu_order use negative number for not shown on menu, default: use in order instantiated into ActionListing
* @param string $next_action
function ActionData($class, $file, $name, $title, $menu, $permissions=
BBROLE_NONE,
$menu_order=
NULL, $next_action=
NULL) {
$this->menu_visible =
($menu_order ===
NULL ||
$menu_order >
0);
$this->next_action =
$next_action ===
NULL ?
$name :
$next_action;
* List of all currently available actions
* Create data structures that can describe both the action-word to be acted
* on, as well as the title to be reflected in the HTML title tag.
* @todo //TODO: this should be integrated with the Menu class
* @todo //TODO: document the fixed up version
/** @var array list of ActionData objects */
/** @var string name of default action when none is explicitly specified in the URL */
/** @todo //TODO:: conditionally initialise these -- at least limit the number of extraneous T_() calls for non admin users */
'forbidden!', T_('No, you cannot do that'), T_('Forbidden'), BBROLE_NONE, -
1);
'calendar', T_('View instrument calendar'), T_('Calendar'), BBROLE_NONE, -
1);
'book', T_('View/edit instrument bookings'), T_('Bookings'), BBROLE_NONE, -
1);
'bookcontact',T_('Requeset an instrument booking'), T_('Request booking'), BBROLE_NONE, -
1);
'instrumentclass', T_('Edit or create instrument class'), T_('Edit instrument class'), BBROLE_ADMIN_COSTS, -
1);
foreach ($actions as $action) {
$this->actions[$action->name()] =
$action;
$this->actions['']->menu_visible =
false;
return isset
($this->actions[$action]);
Documentation generated on Tue, 06 Mar 2007 10:00:30 +0000 by phpDocumentor 1.3.0