Skip to content

sandesh300/Hotel-Booking-React

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

48 Commits
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 
 

Repository files navigation

Hotel Booking App

Introduction

This repository contains the source code for a Hotel Booking App built using Java, Spring Boot, React, MySQL, and JWT authentication. The application allows users to search for hotels, view details, make bookings, and manage their reservations.

Technologies

  • Java: Java is a widely-used programming language known for its portability and versatility. In this project, Java is used for backend development.

  • Spring Boot: Spring Boot is a powerful framework for building Java-based applications quickly and with minimal configuration. It provides tools and plugins for rapid development.

  • React: React is a JavaScript library for building user interfaces. It allows for the creation of interactive and dynamic frontend components.

  • MySQL: MySQL is a popular open-source relational database management system. It is used for storing and managing the application's data, such as hotel information and user bookings.

  • JWT (JSON Web Tokens): JWT is a compact, URL-safe means of representing claims to be transferred between two parties. It is used for secure authentication and authorization in the application.

Features

  • User Authentication: Users can sign up, log in, and log out securely using JWT authentication.

  • Hotel Search: Users can search for hotels based on location, dates, and other criteria.

  • Booking Management: Users can view available rooms, make bookings, and manage their reservations.

  • Admin Panel: Administrators have access to an admin panel where they can manage hotels, rooms, and bookings.

  • Responsive Design: The application is designed to be responsive and accessible on various devices, including desktops, tablets, and mobile phones.

Architectures

The Hotel Booking App follows a client-server architecture:

  • Client-side: The frontend of the application is built using React, which interacts with the backend API to fetch data and manage user interactions.

  • Server-side: The backend is built using Spring Boot, which handles requests from the frontend, processes business logic, and interacts with the database.

  • Database: MySQL is used as the database management system for storing and retrieving application data.

Modules

The application is divided into several modules:

  1. Authentication: Handles user authentication and authorization using JWT tokens.

  2. Hotel Management: Manages hotel information, including details, availability, and pricing.

  3. Booking Management: Handles user bookings, reservation details, and payment processing.

  4. Admin Panel: Provides administrative functionalities for managing hotels, rooms, and user bookings.

Users

The application supports multiple types of users:

  1. Guests: Visitors who can browse hotels and view details but need to sign up or log in to make bookings.

  2. Registered Users: Users who have signed up and logged in can make bookings, manage reservations, and access personalized features.

  3. Administrators: Admin users have access to additional functionalities such as managing hotels, rooms, and bookings through the admin panel.

Additional Points

  • Security: The application prioritizes security measures such as JWT authentication, input validation, and secure communication protocols to protect user data.

  • Scalability: The architecture is designed to be scalable, allowing for future expansion and handling a large number of users and bookings.

  • Testing: Unit tests, integration tests, and end-to-end tests are implemented to ensure the reliability and robustness of the application.

  • Documentation: Detailed documentation is provided for developers, including setup instructions, API documentation, and code explanations.

Getting Started

To run the Hotel Booking App locally, follow these steps:

  1. Clone the repository to your local machine.
  2. Install dependencies for both the frontend and backend.
  3. Set up the MySQL database and configure the application properties.
  4. Run the backend server using Spring Boot.
  5. Run the frontend development server using React.
  6. Access the application through the provided URL and start exploring!

For detailed setup instructions, please refer to the documentation provided in the docs directory.

React + Vite

This template provides a minimal setup to get React working in Vite with HMR and some ESLint rules.

Currently, two official plugins are available: