/The-Family-Restaurant

A family restaurant website with backend support for table bookings

Primary LanguageHTML

The-Family-Restaurant

https://desolate-brook-81890.herokuapp.com/

It is a Family Restaurant website. The home page has a booking page which is disabled if the user is not signed in. Signup or Log in can be done either by manual data entry(Name, email, and password) or directly continuing with your Google or Facebook account. Once the user is signed up, the registration form is open to use, and a user can book tables in the restaurant for any date, time in the future. The person can also check all of his previous booking and modify or delete it if the user choses to. A forgot password option is present in the login section, which will reset the password ONLY if any already registered email-id and the corresponding name of the person is entered, by allowing that user to enter a new password. The Name of person is used as a unique data which is used to link that user from the records of all users, to all the bookings made under the name of that person.

The frontend consists of a homepage, a menu page, a table bookings page( showing details of all the reservations made by the user), a login page, and a sign-up page.The frontend is based on HTML 5,CSS 3,Bootstrap 4,Javascript, Jquery and EJS templating. The website is designed to look great both on desktop as well as mobile devices.

The backend is based on Node.js, Express,js and authentication(local as well as google or facebook) is done using passport.js. MongoDB Atlas is used for storing the website's database, with two collections: users(for authentication purpose), and reservations (details of reservation done by a user). The 'users' collection and 'reservations' are linked by the name of user, which will not be editable(so as to mantain consistency and linking a user data from the 'users' collection to the reservations data done by the user), and will be fetched either from google or facebook (after logging in through them via passport.js strategy) or by manual sign-up by the user and displayed at the home page as Welcome 'Username'.