Skip to content

timzprof/book-a-meal

Repository files navigation

Book A Meal

Book A Meal is an Ecommerce web app , specifically targetted towards bringing caterers and users together. It is built on the PERN(PostgreSQL,Express,React,Node) Stack.

Build Status Coverage Status Maintainability Test Coverage

Getting Started

Clone the Repo.

git clone https://github.com/timzprof/book-a-meal.git

Prerequisites

The following tools will be needed to run this application successfully:

  • Node v10.15.0 or above
  • Npm v6.4 or above

API Endpoints

  • GET api/v1/meals/ Caterers can get all meals options they uploaded
  • POST api/v1/meals/ Catereres can add meal options linked to their account
  • PUT api/vi/meals/:mealId Caterers can update their meal options
  • DELETE api/v1/meals/:mealId Caterers can delete their meal options
  • GET api/v1/menu/ Caterers and Users can Get the menu for the day
  • POST api/v1/menu/ Caterers can Set a menu for the day
  • GET api/v1/orders Get All Orders
  • POST api/v1/orders Users can add Meals to Orders
  • PUT api/v1/orders/:orderId Users can modify their orders (Increment/Decrement/Delete)
  • POST api/v1/orders/checkout Users can checkout their orders

Installation

On your Local Machine

  • Pull the develop branch off this repository
  • Create a PostgreSQL Database for the App
  • Create a .env file and modify the Database Url and Add a Jwt_secret
  • Run npm install to install all dependencies
  • Run npm run dev to start the app (development)
  • Access endpoints on localhost:7000
  • To Access API Docs navigate to localhost:7000/api-docs
  • Cd into the client folder , this contains the React App for this project
  • Run npm install to install all dependencies
  • Cd out of the client folder and run npm run client to start the React App Dev Server
  • Access the React App at localhost:3000

Running the tests

Run npm test in the terminal for the cloned folder.

Built With

Authors

  • Timilehin Olumofin