kepler.models.reservation module¶
The module defines the classes for database models related to reservations.
-
class
kepler.models.reservation.Reservation(time_slot_id, unit_id, unit_group_id, user_group_id, creator_id)¶ Bases:
sqlalchemy.ext.declarative.api.BaseThe SQLAlchemy declarative model class for a
Reservationobject holds information about the user or group who made the reservation and about the time slot containing the reservation.-
created_at¶ The creation time of the reservation.
-
creator_id¶ The user ID of the person who made the reservation.
-
id¶ The ID of the reservation.
-
time_slot_id¶ The reference to the
TimeSlotto which the reservation belongs to.
-
unit_group_id¶ The reference to the
UnitGroupthat the reserved unit belongs to.
-
unit_id¶ The reference to the
Unitthat the reseration was made for.
-
user_group_id¶ The reference to the
UserGroupfor which the reservation was made.
-
-
class
kepler.models.reservation.ReservationStatus(reservation_id, reservation_status_type_id)¶ Bases:
kepler.models.models_meta.ModifiableBase,sqlalchemy.ext.declarative.api.BaseThe SQLAlchemy declarative model class for a
ReservationStatusobject holds information about the status of the reservation (for example, was the reservation cancelled).-
id¶ The reservation status ID.
-
modifier_id¶
-
reservation_id¶ The reference to the
Reservationdatabase table.
-
reservation_status_type_id¶ The reference to the
ReservationStatusTypedatabase table.
-
-
class
kepler.models.reservation.ReservationStatusType(id, name_tr_id)¶ Bases:
sqlalchemy.ext.declarative.api.BaseThe SQLAlchemy declarative model class defines the
ReservationStatusTypeobject that holds the information of different reservation status types.-
active¶ Defines whether the status type is active or has been deactivated.
-
id¶ The ID of the reservation status type.
-
name_tr_id¶ The translation ID of the reservation status type name.
-