Skip to content

rafibz007/RestaurantSPA

Folders and files

NameName
Last commit message
Last commit date

Latest commit

 

History

13 Commits
 
 
 
 
 
 

Repository files navigation

RestaurantSPA

My very first quite simple project in Angular and ExpressJS.
By doing it I have got basic understanding of how these frameworks work.

Especially in Angular I've learned about how components work, how to use services to share data amoung application, split responsibilities, use interceptors, store tokens required for authentication and set up guards.

In ExpressJS I've got to know how to connect to mongdb database, create and manage models, set up routes and secure them using middleware.

Features

  • User Authentication using JWT
  • User roles
  • Browsing, reserving, commenting and rating dishes
  • Adding new or modifying existing dishes

Users in application

AnonymousUser

  • Browse dishes
  • Create new account
  • Login

User:

  • Reserve, comment, rate dishes

Manager:

  • Add, Delete and modify dishes

Admin:

  • Manage user roles
  • Ban users

How to use

Docker - temporarily unavailable

This project was created befeore I though about adding Docker, so unfortunately it is not customizable very much.
Docker compose starts database with custom data.

You should now have access to:

Available accounts: (username-password)

  • admin-admin
  • manager-manager
  • client1-client1
  • client2-client2
  • client3-client3

Start containers:

docker-compose -f docker-compose.yaml up -d

Close containers:

docker-compose -f docker-compose.yaml down

Normal

In "backend" folder ".env" file with provided variables is required:

  • DB_CONNECTION=mongodb+srv://user:password@db
  • JWT_SECRET=secret

Some screenschots

Menu

Screenshot from 2022-03-15 22-31-26

Cart

Screenshot from 2022-03-15 22-30-53

Admin page

Screenshot from 2022-03-15 22-31-52

Dish details and comments

Screenshot from 2022-03-15 22-32-53

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published