Coder Social home page Coder Social logo

django-api's Introduction

Django-api

All the records mentioned in the Sheet have been added in their respective table in SQLite database. using Querry.sql

Futher on going into questions Postman has been used to GET/ POST the records as per the requirements.

  1. Create an API to perform operations on Sales, Product Master, and Branch Master to get required results -> It can be found on http://127.0.0.1:8000/JoinOperationAPI below is the image of Json records fetched from Postman with Date, ProductID, BranchID, Price, Quantity, ProductName, Category, BranchName, City column respectively. Postman JoinOperationAPI

  2. Create an API and use Purchase Orders to calculate the following 2 things: a.) Add a column ‘lead time’: Lead time is the difference between the received date and the ordered date in days

    -> This column has been fetched from API(http://127.0.0.1:8000/LeadTimeAPI) and in sql Querry both image of which can be found below Postman LeadTimeAPI SQL LeadTimeAPI

    b.)Calculate lead time average for each Product ID-Branch ID-Supplier ID combination.
    -> The below json records are in ProductID,BranchId,SupplierId,AvgLeadTime column wise respectively Postman AvgLeadTime

  3. Create an API to insert a new Sales record Previous records in Sales Table (http://127.0.0.1:8000/sales) Postman SaleRecords
    New record Date Product ID Branch ID Price Quantity '2021-11-03', 1, 100, 10, 150 Added using POST method

    Postman Added
    Updated record in Sales API Postman NewSaleRecords

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.