A comprehensive Java desktop application for managing travel bookings, packages, and user accounts with an intuitive interface and robust backend functionality.
- User authentication and registration
- Browse and search travel packages
- Book travel packages
- View and cancel bookings
- Secure password handling
- Interactive user dashboard
- Detailed travel package information with images
- Java
- Swing for GUI
- MySQL for database storage
- JDBC for database connectivity
- MVC (Model-View-Controller) architecture
- Properties files for configuration management
- Custom exception handling
- JDK 8 or higher
- MySQL Server 5.7 or higher
- MySQL Connector/J (JDBC driver)
- Install MySQL Server if not already installed
- Create a new database named
tbs - Import the provided SQL schema from
database/tbs_schema.sql
<Enter your password>
SOURCE database/tbs_schema.sql;- Navigate to the
configdirectory - Rename
db.properties.exampletodb.properties - Edit
db.propertiesand update with your MySQL credentials:
db.url=jdbc:mysql://localhost:3306/tbs
db.user=your_username
db.password=your_password- Create a "lib" folder in src directory
- Download the MySQL JDBC driver
- Unzip the downloaded folder and copy the JAR file of the driver
- Paste the JAR file into the lib directory you created
- Import the project into your IDE
- Download and the MySQL JDBC connector to your project's classpath or 'lib' directory
- Run the
App.javafile as the main class
- Navigate to the project root directory
- Compile the Java files:
javac -d bin -cp lib/mysql-connector-java.jar src/*.java src/**/*.java- Run the application:
java -cp bin:lib/mysql-connector-java.jar AppFor Windows, use ; instead of : in the classpath:
java -cp bin;lib/mysql-connector-java.jar AppTBS/
├── src/ # Source code
│ ├── db/ # Database connection code
│ ├── exception/ # Custom exceptions
│ ├── model/ # Data models
│ ├── service/ # Business logic
│ ├── ui/ # User interface
│ ├── utils/ # Utility classes
│ └── App.java # Main application entry
├── config/ # Configuration files
│ └── db.properties # Database configuration (not in git)
├── database/ # SQL scripts
│ └── tbs_schema.sql # Database schema
├── lib/ # External libraries/dependencies
└── README.md # This file
- Login Screen: Enter credentials or register a new account
- New users can register from the login screen
- Home Page: Browse available travel packages
- Package Details: View detailed information and book packages
- Package descriptions, itineraries, and included amenities
- My Bookings: View and manage your bookings
- See booking status (Confirmed, Cancelled)
- Cancel bookings with applicable refund policy
The application follows the MVC (Model-View-Controller) pattern:
- Models: Represent data structures (User, Package, Booking)
- Views: Swing GUI components for user interaction
- Controllers: Handle user input and update models/views
This project is for educational purposes only. Not for commercial use.