Kantoor.Bookings.Booking (Kantoor v1.0.0)

One appointment made through a booking page.

The event itself lives in the host's calendar as an ordinary VEVENT (event_id, calendar); this row remembers who booked, when (in the host's wall clock), and the hash of the manage token that was e-mailed to the booker. Only the hash is stored, so a copy of the database does not give anyone the power to move or cancel an appointment.

Summary

Functions

Marks a booking cancelled.

Creates a booking row.

Changes the times of a confirmed booking (a move).

Every status a booking can have.

Types

t()

@type t() :: %Kantoor.Bookings.Booking{
  __meta__: term(),
  booker_email: term(),
  booker_name: term(),
  booking_page: term(),
  booking_page_id: term(),
  calendar: term(),
  cancelled_at: term(),
  ends_at: term(),
  event_id: term(),
  id: term(),
  inserted_at: term(),
  manage_token_hash: term(),
  note: term(),
  sequence: term(),
  starts_at: term(),
  status: term(),
  uid: term(),
  updated_at: term(),
  zone: term()
}

Functions

cancel_changeset(booking)

Marks a booking cancelled.

changeset(booking, attrs)

Creates a booking row.

move_changeset(booking, attrs)

Changes the times of a confirmed booking (a move).

statuses()

Every status a booking can have.