Boomerang Airline Reservation System was created to make it easier for users to reserve round trips through different options and airlines and be able to choose the best routes or flights according to their preferences.
The project build status now is completed successfully with no current errors.
This is the Sign In page where the user can enter their username and password.
This is the Sign Up page where the user can sign up for the website.
The user can search for flights using search criteria including Departure Airport, Arrival Airport, Departure Date, Arrival Date
This project was implemented using MERN stack,so for someone to use/edit this project they need a basic understanding of React.js, HTML & CSS which were used for the frontend and Node.js which was used for the backend in addition to JavaScript and Express Js and MongoDB Atlas was used for the database.
- The user can email himself/herself their reservation itinerary at any time.
- The departure/return flights can be changed at any time even after paying for the reservation(taking into account that the price difference will have to be paid).
- The users can view all their previous bookings or history at any time using “My bookings”.
Veryfing Token for the user
const token = req.headers["x-access-token"]?.split(" ")[1];
console.log(token);
if (token) {
jwt.verify(token, process.env.JWT_SECRET, (err, decoded) => {
if (err)
return res.json({
isLoggedIn: false,
message: "Failed To Authenticate",
});
req.user = {};
req.user._id = decoded.id;
req.user.UserName = decoded.username;
next();
});
} else {
res.json({ message: "Incorrect Token Given", isLoggedIn: false });
}
};
- Install VS Code or any similar IDE https://code.visualstudio.com/download
- Install NodeJs https://nodejs.org/en/download/
- NodeMailer: https://nodemailer.com/about/
- Stripe: https://stripe.com/docs/api
- Clone the full-stack branch in the repository on your VS Code
- Create your own .env file which includes:
- mongoURI = //your mongoDB URL
- PORT = //your server port number to run the server
- PORTA = //your client port number to run the user interface
- JWT_SECRET = //any string of your choice to use in hashing the users’ passwords
- In your VS Code terminal in order to run the server you’ll run the following commands
cd Cheetos
cd server
npm i
node app.js
- In your VS Code terminal in order to run the client you’ll run the following commands
cd Cheetos
cd client
npm i
npm start
Pull requests are welcome. For major changes, please open an issue first to discuss what you would like to change. Please make sure to update tests as appropriate. As for pushing guidelines:
- Create a separate branch for your modifications if it is your first time to modify, if not commit to your previously created branch.
- You should always resolve conflicts and make sure that no changes that were made previously are lost.
- https://dev.to/salarc123/mern-stack-authentication-tutorial-part-1-the-backend-1c57
- https://www.geeksforgeeks.org/node-js-crud-operations-using-mongoose-and-mongodb-atlas/
- https://blog.logrocket.com/mern-stack-tutorial/
- https://reactjs.org/docs/create-a-new-react-app.html
- https://nodemailer.com/about/