You are here

function bat_booking_load in Booking and Availability Management Tools for Drupal 7

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

Fetches a booking object.

Parameters

int $booking_id: Integer specifying the booking id.

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

Return value

BatBooking|false A fully-loaded $booking object or FALSE if it cannot be loaded.

See also

bat_booking_load_multiple()

1 call to bat_booking_load()
bat_booking_handler_night_field::render in modules/bat_booking/views/bat_booking_handler_night_field.inc
Render the field.

File

modules/bat_booking/bat_booking.module, line 469

Code

function bat_booking_load($booking_id, $reset = FALSE) {
  $bookings = bat_booking_load_multiple(array(
    $booking_id,
  ), array(), $reset);
  return reset($bookings);
}