export type BookingMode = "Scheduled" | "AdHoc" /** Mirrors FacilityDto. A bookable area (gym floor, pool, court, class) that's also the * access-control zone for its optional fingerprint/face terminal — merged from the former * separate Facility/Place concepts. */ export interface Facility { facilityId: string name: string bookingMode: BookingMode description?: string | null /** Meaningful when bookingMode === "Scheduled" — shared capacity per session. */ defaultCapacity: number /** Meaningful when bookingMode === "AdHoc" — e.g. 3 for "3 courts", each independently bookable. */ numberOfUnits: number pricePerHour: number isActive: boolean createdAt: string deviceId?: string | null deviceName?: string | null } export interface FacilityInput { name: string bookingMode: BookingMode description?: string defaultCapacity: number numberOfUnits: number pricePerHour: number } /** Mirrors FacilitySessionDto. */ export interface FacilitySession { facilitySessionId: string facilityId: string facilityName?: string | null startTime: string endTime: string capacity: number bookedCount: number isCancelled: boolean } export interface FacilitySessionInput { facilityId: string startTime: string endTime: string /** Overrides the facility's default capacity for this specific session. */ capacity?: number } /** Mirrors FacilityAvailabilityDto. */ export interface FacilityAvailability { facilityId: string facilityName: string bookingMode: BookingMode totalUnits: number unitsFree: number pricePerHour: number }