You are here

function bat_event_access in Booking and Availability Management Tools for Drupal 7

Same name and namespace in other branches
  1. 8 modules/bat_event/bat_event.module \bat_event_access()

Checks event access for various operations.

Parameters

string $op: The operation being performed. One of 'view', 'update', 'create' or 'delete'.

object $event: Optionally an event to check access for.

object $account: The user to check for. Leave it to NULL to check for the current user.

Return value

bool Boolean indicating if the defined user has access to the event or not.

7 calls to bat_event_access()
bat_event_add_access in modules/bat_event/bat_event.module
Access callback: Checks whether the user has permission to add an event.
bat_event_edit_form in modules/bat_event/bat_event.admin.inc
Form callback: create or edit a event.
bat_event_handler_delete_link_field::render in modules/bat_event/views/bat_event_handler_delete_link_field.inc
Render the field.
bat_event_handler_edit_link_field::render in modules/bat_event/views/bat_event_handler_edit_link_field.inc
Render the field.
bat_fullcalendar_event_management_access in modules/bat_fullcalendar/bat_fullcalendar.module
The EventManager page access callback.

... See full list

2 string references to 'bat_event_access'
BatEventUIController::hook_menu in modules/bat_event/bat_event.admin.inc
Overrides hook_menu() defaults.
bat_event_entity_info in modules/bat_event/bat_event.module
Implements hook_entity_info().

File

modules/bat_event/bat_event.module, line 745
Manage Events - Events store the EventValue of a Unit over a period of time.

Code

function bat_event_access($op, $event = NULL, $account = NULL) {
  return bat_entity_access($op, $event, $account, 'bat_event');
}