Web-based Flight Reservation System built with ASP.NET Core 8.0 MVC and Entity Framework Core 9.0. Full CRUD for flights, passengers, and bookings with User and Admin role authentication.
Related: SRS-for-flight-system — full system documentation, SRS, SDD, and RTM.
| Flights List | Booking Details | Login |
|---|---|---|
![]() |
![]() |
![]() |
Run locally (
dotnet run) and navigate tohttps://localhost:{PORT}/Flights.
| Layer | Technology |
|---|---|
| Framework | ASP.NET Core 8.0 MVC |
| ORM | Entity Framework Core 9.0 (Code-First) |
| Views | Razor (.cshtml) + Bootstrap 4 |
| Auth | Custom login — User and Admin tables |
| Database | SQL Server / LocalDB |
- Flight Management — CRUD with search by flight number; sort by number, origin, destination, price
- Passenger Management — CRUD for passenger records
- Bookings — Many-to-many Flight ↔ Passenger via
FlightPassengerjoin table; Details view shows all passengers and total cost - User Auth — Sign up / login for both User and Admin accounts
- Flight Types — Domestic and International (enum)
| Model | Key Fields |
|---|---|
| Flight | Id, FlightNumber, Origin, Destination, DepartureTime, ArrivalTime, SeatCapacity, Type, Price |
| Passenger | PassengerId, FullName, Email, ContactNumber |
| FlightPassenger | Id, FlightId (FK), PassengerId (FK) |
| User | Id, Name, username, password |
| Admin | AdminId, Name, username, password |
FlightReservationApp/
├── Controllers/ # MVC controllers
├── Data/ # EF Core DataContext
├── Models/ # Entity models
├── Views/ # Razor views per controller
├── Migrations/ # EF Core migrations
└── wwwroot/ # Static assets
Prerequisites: .NET 8.0 SDK · SQL Server or LocalDB
git clone https://github.com/omaralrayyan7/Flight-reservation-system.git
cd Flight-reservation-system
# Update connection string in appsettings.json, then:
dotnet ef database update
dotnet runApp opens at https://localhost:{PORT}/Flights.


