public function AvailabilityAgent::setValidStates in Rooms - Drupal Booking for Hotels, B&Bs and Vacation Rentals 7
Sets the valid states for an availability search.
Defaults are "ROOMS_AVAILABLE" and "ROOMS_ON_REQUEST"
Parameters
array $states: The valid states to perform the search.
File
- modules/
rooms_booking/ includes/ rooms_booking.availability_agent.inc, line 128 - Contains the AvailabilityAgent.
Class
- AvailabilityAgent
- An AvailabilityAgent provides access to the availability functionality of Rooms and lets you query for availability, get pricing information and create products that can be bought.
Code
public function setValidStates($states = array(
ROOMS_AVAILABLE,
ROOMS_ON_REQUEST,
ROOMS_UNCONFIRMED_BOOKINGS,
)) {
$this->valid_states = $states;
}