You are here

function bat_event_load_multiple 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_load_multiple()

Load multiple events based on certain conditions.

Parameters

array $event_ids: An array of event IDs.

bool $reset: A boolean indicating that the internal cache should be reset.

Return value

array An array of event objects, indexed by event_id.

See also

bat_event_load()

4 calls to bat_event_load_multiple()
bat_event_ids in modules/bat_event/bat_event.module
Get a list of Event keyed by id and name in value.
EventSeriesDeleteEventsForm::buildForm in modules/bat_event_series/src/Entity/Form/EventSeriesDeleteEventsForm.php
Form constructor.
EventSeriesDeleteForm::buildForm in modules/bat_event_series/src/Entity/Form/EventSeriesDeleteForm.php
Form constructor.
EventSeriesDeleteForm::submitForm in modules/bat_event_series/src/Entity/Form/EventSeriesDeleteForm.php
This is the default entity object builder function. It is called before any other submit handler to build the new entity object to be used by the following submit handlers. At this point of the form workflow the entity is validated and the form state…

File

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

Code

function bat_event_load_multiple(array $event_ids = NULL, $reset = FALSE) {
  if ($reset) {
    \Drupal::entityTypeManager()
      ->getStorage('bat_event')
      ->resetCache($event_ids);
  }
  return Event::loadMultiple($event_ids);
}