Git Product home page Git Product logo

pizza-system's Introduction

Pizza-System

Tech Stack

  • Language: Python
  • Framework: Django
  • Database: PostgreSQL
  • ORM: Django ORM
  • Services: Docker, Celery, Redis

Additonal Info

  • Added Unit Testing

  • MySQL was causing problems with my path variables, which is why I switched to PostgreSQL.

Database Design :

image

Unit Testing for the API's

  1. I have added unit testing in the docker script so no need to expliclity run that -Screenshot 2023-11-24 at 4 11 09 PM

Running the System

  1. Change the directory to cd pizza_delivery.

  2. Build and run the system with Docker Compose: docker-compose up --build

  3. Open Postman and test the endpoints, Please follow the steps given below ( Need to add atleast 5 Toppings )

Create Pizza Base Endpoint

  • Endpoint: localhost:8000/pizza-ordering/api/create_pizza_base/
  • 281053710-401a426c-fd6b-41e6-80f4-45236aa8c261

Create Cheese Endpoint

  • Endpoint: localhost:8000/pizza-ordering/api/create_cheese/
  • image

Create Toppings Endpoint

  • Endpoint: localhost:8000/pizza-ordering/api/create_topping/
  • image

Create Pizza Endpoint

  • Endpoint: localhost:8000/pizza-ordering/api/create_pizzas/
  • Additional Info: You need to provide the ID assigned to the topping name.
  • 281054543-6875cf72-5102-40b1-9198-4f63e09b6f2c

Create Orders Endpoint

  • Endpoint: localhost:8000/pizza-ordering/api/create_orders/

  • Additional Info: Celery task will automatically be assigned; no need to run Redis server and Celery from your side. These services are also included in Docker.

  • 281054961-3d556f29-a3a4-4f0d-80b6-4529c286384f
  • The image shows that the Celery task is working on the conditions.

  • 281055437-29bd5256-e4b1-47ce-aa5c-83099342dce8

List of All Orders Endpoint

  • Endpoint: http://localhost:8000/pizza-ordering/api/orders/
  • 281055677-32882baf-d236-408e-996d-9e6a4a238bfc

List of All Pizzas

  • Endpoint: http://localhost:8000/pizza-ordering/api/pizzas/
  • 281056332-582c3447-c8e4-4052-aba3-efa90620456e

Get a Single Entry of an Order

  • Endpoint: http://localhost:8000/pizza-ordering/api/order/id
  • 281056802-a46fc478-9c81-4d42-8493-109fa94f1242

Get a Single Entry of Pizza Base, Cheese, Topping, Pizza

  • Endpoints:
  • http://localhost:8000/pizza-ordering/api/pizza_base/id
  • http://localhost:8000/pizza-ordering/api/cheese/id
  • http://localhost:8000/pizza-ordering/api/topping/id
  • http://localhost:8000/pizza-ordering/api/pizza/id
  • http://localhost:8000/pizza-ordering/api/topping/id

pizza-system's People

Contributors

gulshantelkar avatar telkargulshan avatar

Watchers

 avatar

Recommend Projects

  • React photo React

    A declarative, efficient, and flexible JavaScript library for building user interfaces.

  • Vue.js photo Vue.js

    🖖 Vue.js is a progressive, incrementally-adoptable JavaScript framework for building UI on the web.

  • Typescript photo Typescript

    TypeScript is a superset of JavaScript that compiles to clean JavaScript output.

  • TensorFlow photo TensorFlow

    An Open Source Machine Learning Framework for Everyone

  • Django photo Django

    The Web framework for perfectionists with deadlines.

  • D3 photo D3

    Bring data to life with SVG, Canvas and HTML. 📊📈🎉

Recommend Topics

  • javascript

    JavaScript (JS) is a lightweight interpreted programming language with first-class functions.

  • web

    Some thing interesting about web. New door for the world.

  • server

    A server is a program made to process requests and deliver data to clients.

  • Machine learning

    Machine learning is a way of modeling and interpreting data that allows a piece of software to respond intelligently.

  • Game

    Some thing interesting about game, make everyone happy.

Recommend Org

  • Facebook photo Facebook

    We are working to build community through open source technology. NB: members must have two-factor auth.

  • Microsoft photo Microsoft

    Open source projects and samples from Microsoft.

  • Google photo Google

    Google ❤️ Open Source for everyone.

  • D3 photo D3

    Data-Driven Documents codes.