Bookings Entity Structure
This JSON file defines the Bookings entity in the system. It outlines how booking details are structured, stored, and managed within both the backend (database) and frontend (user interface) components of the system.
At the top level, the bookings
object describes the overall configuration for the Bookings entity.
Properties of the Bookings Entity
Each field defines a different attribute or column in the Bookings entity, and each one has its specific properties.
The Bookings entity manages data about bookings, including fields such as:
- id: Unique identifier for the booking.
- traveler_id: Refers to the traveler who made the booking. This field is a foreign key linked to the Traveler entity.
- flight_id: Refers to the flight for which the booking is made. This field is a foreign key linked to the Flight entity.
- arrival_date_and_time: The scheduled arrival date and time of the flight. This field is derived from the Flight entity.
- departure_date_and_time: The scheduled departure date and time of the flight. This field is derived from the Flight entity.
The Bookings entity is exposed in both the UI and API. The fields are indexed for quick lookups, and some fields are optional. The Bookings entity is grouped into a block called Bookings Details for easy presentation in the UI. This configuration allows users and external systems to manage and access booking data within a broader system, such as a travel management system.
Relationships
- One Traveler can have many Bookings.
- One Flight can have many Bookings.
Flight Entity Structure
This JSON file defines the Flight entity in the system. It outlines how flight details are structured, stored, and managed within both the backend (database) and frontend (user interface) components of the system.
At the top level, the flight
object describes the overall configuration for the Flight entity.
Properties of the Flight Entity
Each field defines a different attribute or column in the Flight entity, and each one has its specific properties.
The Flight entity manages data about flights, including fields such as:
- id: Unique identifier for the flight.
- flight_name: The name of the flight, often used for display purposes.
- airline_id: Refers to the airline operating the flight. This field is a foreign key linked to the Airline entity.
- destination_location_id: Refers to the location where the flight will arrive, linked to the Location entity.
- departure_location_id: Refers to the location where the flight will depart, linked to the Location entity.
- departure_date_and_time: The scheduled departure date and time for the flight.
- arrival_date_and_time: The scheduled arrival date and time for the flight.
- status: Current status of the flight (e.g., scheduled, delayed, cancelled).
The Flight entity is exposed in both the UI and API. The fields are indexed for quick lookups, and many of them are optional. The Flight entity is grouped into a block called Flight Details for easy presentation in the UI. This configuration allows users and external systems to manage and access flight data within a broader system, such as a booking system.
Relationships
- One Airline can operate many Flights.
- One Flight can have many Bookings.
Airline Entity Structure
This JSON file defines the Airline entity in the system. It outlines how airline details are structured, stored, and managed within both the backend (database) and frontend (user interface) components of the system.
At the top level, the airline
object describes the overall configuration for the Airline entity.
Properties of the Airline Entity
Each field defines a different attribute or column in the Airline entity, and each one has its specific properties.
The Airline entity manages data about airlines, including fields such as:
- id: Unique identifier for the airline.
- name: The name of the airline, often used for display purposes in lists and forms.
- code: The airline code, a unique identifier (e.g., IATA code) that distinguishes airlines from each other.
The Airline entity is only exposed through the API but not in the UI. The fields are indexed for efficient lookups, and all fields are required. The Airline entity is grouped into a block called Airline Details for structured organization. This configuration allows external systems to manage airline data, which can be used within the broader system, such as a flight booking or scheduling system.
Field-specific Details
- id: This field is the primary key for the airline and must be a unique string up to 40 characters in length.
- name: This is a required string field with a length limit of 128 characters. It is displayed with the heading Airline Name in lists, and its entry form includes a textbox component with a hint to guide the user.
- code: This is a required string field (up to 128 characters) that represents the airline's unique code. It is displayed with the heading Code in lists, and its entry form also includes a textbox component with a hint.
Relationships
The Airline entity typically relates to the Flight entity. For example:
- One Airline can operate many Flights.
This structure ensures that airline data can be efficiently managed and accessed by other entities such as Flights, facilitating integration with systems like flight management or booking services.
Location Entity Structure
This JSON file defines the Location entity in the system. It outlines how location details are structured, stored, and managed within both the backend (database) and frontend (user interface) components of the system.
At the top level, the location
object describes the overall configuration for the Location entity.
Properties of the Location Entity
Each field defines a different attribute or column in the Location entity, and each one has its specific properties.
The Location entity manages data about locations, including fields such as:
- id: Unique identifier for the location.
- airport_name: The name of the airport, often used for display purposes.
- code: The unique code for the location, which distinguishes it from other locations.
The Location entity is exposed in both the UI and API. The fields are indexed for quick lookups, and all fields are required. The Location entity is grouped into a block called Location Details for easy presentation in the UI. This configuration allows users and external systems to manage and access location data within a broader system, such as a flight booking system.
Relationships
- One Location can be associated with many Flights.
This structure ensures that location data is efficiently managed and linked to other entities like Flights within the system.
Passport Entity Structure
This JSON file defines the Passport entity in the system. It outlines how passport details are structured, stored, and managed within both the backend (database) and frontend (user interface) components of the system.
At the top level, the passport
object describes the overall configuration for the Passport entity.
Properties of the Passport Entity
Each field defines a different attribute or column in the Passport entity, and each one has its specific properties.
The Passport entity manages data about passports, including fields such as:
- id: Unique identifier for the passport.
- full_name: The full name of the passport holder, often used for display purposes.
- passport_number: The unique number assigned to the passport.
- nationality: The nationality of the passport holder.
The Passport entity is exposed in both the UI and API. The fields are indexed for quick lookups, and all fields are required. The Passport entity is grouped into a block called Passport Details for easy presentation in the UI. This configuration allows users and external systems to manage and access passport data within a broader system, such as a flight booking or travel management system.
Field-specific Details
- full_name: This is a required string field with a length limit of 128 characters. It is displayed with the heading Passport Name in lists, and its entry form includes a textbox component with a hint to guide the user.
- passport_number: This is a required string field with a length limit of 128 characters. It is displayed with the heading Passport Number in lists, and its entry form also includes a textbox component with a hint.
- nationality: This is a required string field with a length limit of 128 characters. It is displayed with the heading Nationality in lists, and its entry form includes a textbox component with a hint.
Relationships
- One Passport can be linked to many Bookings.
This structure ensures that passport data is efficiently managed and linked to other entities like Bookings within the system.
Traveler Entity Structure
This JSON file defines the Traveler entity in the system. It outlines how traveler details are structured, stored, and managed within both the backend (database) and frontend (user interface) components of the system.
At the top level, the traveler
object describes the overall configuration for the Traveler entity.
Properties of the Traveler Entity
Each field defines a different attribute or column in the Traveler entity, and each one has its specific properties.
The Traveler entity manages data about travelers, including fields such as:
- id: Unique identifier for the traveler.
- name: The name of the traveler, often used for display purposes.
- traveler_gender: The gender of the traveler.
- passport_id: Refers to the passport of the traveler. This field is a foreign key linked to the Passport entity.
The Traveler entity is exposed in both the UI and API. The fields are indexed for quick lookups, and the id field is required while others are optional. The Traveler entity is grouped into a block called Traveler Details for easy presentation in the UI. This configuration allows users and external systems to manage and access traveler data within a broader system, such as a flight booking system.
Field-specific Details
- name: This is an optional string field with a length limit of 128 characters.
- traveler_gender: This is an optional string field with a length limit of 128 characters.
- passport_id: This is an optional string field with a length limit of 128 characters. It serves as a foreign key that links to the Passport entity.
Relationships
- One Traveler can be associated with one Passport.
- One Passport can be linked to many Travelers.
This structure ensures that traveler data is efficiently managed and linked to other entities like Passport within the system.
Relationships between Entities
-
Traveler to Passport (One-to-One)
- Each traveler can have one associated passport. This relationship ensures that the traveler's identification is linked to their passport.
-
Traveler to Bookings (One-to-Many)
- A traveler can make multiple bookings, allowing for a traveler to book various flights over time.
-
Flight to Bookings (One-to-Many)
- Each flight can have multiple bookings associated with it, allowing many travelers to book the same flight.
-
Airline to Flight (One-to-Many)
- An airline can operate multiple flights, indicating which airline serves which routes.
-
Location to Flight (One-to-Many)
- A location (such as an airport) can have multiple flights arriving at or departing from it.