MagicSmoke
$VERSION$
|
This class is used to verify tickets in a new order and to assign seats. More...
Public Member Functions | |
__construct ($eventid) | |
creates a new EventPlan object by the event ID it represents automatically loads the seat plan and all tickets More... | |
addTickets ($key, &$ticket) | |
adds the ticket to the list of new tickets and validates whether the sale is possible; does not validate the sale timing, this is done in the cart using eventHasStarted and eventHasEnded; adjusts the ticket state in case of failure More... | |
canSellEvent () | |
returns true if the user can sell for this event in general, ie. More... | |
eventHasEnded ($timestamp) | |
checks whether the event has already ended at the given timestamp More... | |
eventHasStarted ($timestamp) | |
checks whether the event has already started at the given timestamp More... | |
eventIsValid () | |
returns true if the references event exists More... | |
getEvent () | |
returns the event More... | |
getTickets () | |
returns the newly added ticket objects (array of WOCartTicket) More... | |
This class is used to verify tickets in a new order and to assign seats.
EventPlan::__construct | ( | $eventid | ) |
creates a new EventPlan object by the event ID it represents automatically loads the seat plan and all tickets
References $db, WOSeatPlanAbstract\fromString(), WOTicketAbstract\fromTableArrayticket(), WOEventAbstract\fromTableevent(), WTevent\getFromDB(), and WTticket\selectFromDB().
EventPlan::addTickets | ( | $key, | |
& | $ticket | ||
) |
adds the ticket to the list of new tickets and validates whether the sale is possible; does not validate the sale timing, this is done in the cart using eventHasStarted and eventHasEnded; adjusts the ticket state in case of failure
References canSellEvent(), WOCartTicket\Exhausted, WOCartTicket\Invalid, and tr().
EventPlan::canSellEvent | ( | ) |
returns true if the user can sell for this event in general, ie.
:
References eventIsValid().
Referenced by addTickets().
EventPlan::eventHasEnded | ( | $timestamp | ) |
checks whether the event has already ended at the given timestamp
EventPlan::eventHasStarted | ( | $timestamp | ) |
checks whether the event has already started at the given timestamp
EventPlan::eventIsValid | ( | ) |
returns true if the references event exists
Referenced by canSellEvent().
EventPlan::getEvent | ( | ) |
returns the event
EventPlan::getTickets | ( | ) |
returns the newly added ticket objects (array of WOCartTicket)