You are here

function bat_event_type_load in Booking and Availability Management Tools for Drupal 8

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

Menu argument loader; Load a event type by string.

Parameters

string $type: The machine-readable name of a event type to load.

Return value

\Drupal\bat_event\Entity\EventType|null An event type array or NULL if $type does not exist.

22 calls to bat_event_type_load()
BatCalendarReferenceMonthView::viewElements in modules/bat_calendar_reference/src/Plugin/Field/FieldFormatter/BatCalendarReferenceMonthView.php
Builds a renderable array for a field value.
BatCalendarReferenceTimelineView::viewElements in modules/bat_calendar_reference/src/Plugin/Field/FieldFormatter/BatCalendarReferenceTimelineView.php
Builds a renderable array for a field value.
BatCalendarReferenceUnitAutocomplete::formElement in modules/bat_calendar_reference/src/Plugin/Field/FieldWidget/BatCalendarReferenceUnitAutocomplete.php
Returns the form for a single field widget.
BatCalendarReferenceUnitTypeAutocomplete::formElement in modules/bat_calendar_reference/src/Plugin/Field/FieldWidget/BatCalendarReferenceUnitTypeAutocomplete.php
Returns the form for a single field widget.
BatEventHandlerEventTypeField::render in modules/bat_event/src/Plugin/views/field/BatEventHandlerEventTypeField.php
Renders the field.

... See full list

File

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

Code

function bat_event_type_load($type) {
  return EventType::load($type);
}