-
Notifications
You must be signed in to change notification settings - Fork 9
Booking Features
This document covers the booking-related features in the Effective Office tablet client application. These features enable users to create, modify, and manage room reservations through various interfaces including a full booking editor, fast booking for immediate needs, and room release functionality.
For information about the backend booking management system, see Booking Management. For details about room display and availability visualization, see Room Display & Slot Management.
The booking features are implemented as three main feature modules in the tablet client:
| Feature | Purpose | Primary Component |
|---|---|---|
| Booking Editor | Create and edit detailed bookings | BookingEditorComponent |
| Fast Booking | Quick room reservations | FastBookingComponent |
| Room Release | Free up occupied rooms | FreeSelectRoomComponent |
These features integrate with the core domain layer for business logic and use shared UI components for consistent user experience.
The booking editor provides a comprehensive interface for creating new bookings and modifying existing ones. It supports full customization of booking parameters including date, time, duration, and organizer selection.
The BookingEditorComponent handles several core responsibilities:
-
Event Creation and Updates: Creates new bookings via
createBookingUseCaseand updates existing ones viaupdateBookingUseCase -
Conflict Detection: Uses
checkBookingUseCaseto identify scheduling conflicts with existing bookings -
Organizer Management: Loads and filters organizers through
organizersInfoUseCasewith autocomplete functionality - Validation: Validates booking parameters including time constraints and organizer selection
The booking editor operates through different modal configurations defined in BookingEditorComponent.ModalConfig:
| Modal Type | Purpose | Trigger |
|---|---|---|
UpdateModal |
Main editing interface | Default state |
SuccessModal |
Booking confirmation | Successful creation/update |
FailureModal |
Error handling | Booking conflicts or errors |
The booking editor state is managed through a comprehensive State data class that tracks:
Fast booking enables immediate room reservations with minimal user interaction. It automatically finds available rooms and creates bookings with predefined durations.
The fast booking feature implements intelligent room selection through the SelectRoomUseCase:
- Primary Selection: Attempts to book the currently selected room if available for the requested duration
- Fallback Selection: If the primary room is unavailable, finds the next available room from the room list
- Wait Time Calculation: When no rooms are immediately available, calculates the shortest wait time until a room becomes free
Fast booking supports predefined duration options accessible through the main interface:
| Duration | Use Case |
|---|---|
| 15 minutes | Brief meetings, quick calls |
| 30 minutes | Standard short meetings |
| 60 minutes | Extended discussions |
The room release feature allows users to immediately free up occupied rooms by canceling active bookings.
The FreeSelectRoomComponent provides a simple interface for room release:
- Accepts an
EventInfoobject representing the booking to cancel - Uses
DeleteBookingUseCaseto remove the booking from the system - Manages loading state during the deletion process
- Automatically closes the interface upon successful completion
All booking features implement comprehensive error handling:
- Validation Errors: Time in past, invalid organizer selection, scheduling conflicts
- Network Errors: Backend communication failures during booking operations
- Business Logic Errors: Room availability conflicts, booking permission issues
Error states are managed through dedicated boolean flags in each component's state and displayed through appropriate modal interfaces.