Skip to content

mondaysunrise/middleman-be

 
 

Repository files navigation

Middleman-Apps

Logo
BE TEAM

💻 About The Project

Middleman is a project for helping each store for buying some products for stock on distributor via online. In real case, many store that still doing manual for listing stock product, add / reduce for in/out stock product, take a notes for stock of their products. So therefore, Middleman is developed here trying for handle that behaviour user which changing from manual to all stock activity in online.

Feature in Middleman

🙎 Users

In users, there is a feature to login either user or admin, we also create Create, Read, Update, Delete for users here

Feature User Endpoint Param JWT Token Function
GET /users/products - YES get all data product user
POST /users/products - YES add product (not available in distributtor)
GET /users/products/search productname YES serach product
PUT /users/products idproduct YES update product (not available in distributtor)
DELETE /users/products idproduct YES delete product (users)
📋 User Product

In User Product, there is a feature to Create, Read, Update, Delete product but not available in product Admin

Feature User Product Endpoint Param JWT Token Function
POST /admins/products - YES new product by Admin
GET /admins/products - NO get all product sell
GET /admins/products/search productname NO serach product
PUT /admins/products idproduct YES update product by Admin
DELETE /admins/products idproduct YES delete product by id
🛒 Carts

In Carts for user to create Cart before order

Feature Cart Endpoint Param JWT Token Function
GET /carts - YES get all product in cart by user
POST /carts - YES add product in cart
PUT /carts idproduct YES update cart
DELETE /carts idproduct YES delete cart
👨‍💻 Admin Product

In Admin, there is a feature to Create, Read, Update, Delete product to shell in application

Feature Admin Endpoint Param JWT Token Function
POST /admins/products - YES new product by Admin
GET /admins/products - NO get all product sell
GET /admins/products/search idproduct NO serach product
PUT /admins/products idproduct YES update product by Admin
DELETE /admins/products idproduct YES delete product by id
🛍️ Order

In Order, feature to transaction order

Feature Order Endpoint Param JWT Token Function
POST /orders/users - YES create new order user
GET /orders/users - YES get all history order
GET /orders/ idorder YES get detail order user and admin
GET /orders/admins - YES get all history order admin
GET /orders/admins/incoming - YES get incomming order from user (ADMIN)
PUT /orders/confrim/ idorder YES confrim order by id(ADMIN)
PUT /orders/done/ idorder YES finish order by id(ADMIN)
📜 Inoutbounds

In Inoutbounds feature handle realation stok in admin and user. if admin out == user in

Feature Order Endpoint Param JWT Token Function
GET /inoutbounds - YES get cart for stock user (out) and stok admin (in)
POST /inoutbounds - YES create new cart for stock user (out) and stok admin(in)
PUT /inoutbounds/ idproducts YES update quantity product in carts for stock user (out) and admin (in)
DELETE /inoutbounds/ idproducts YES delete product by id in carts for stock user (out) and admin (in)
📊 Inventories

In Inventories feature to record stok in and out from inventory user admin

Feature Order Endpoint Param JWT Token Function
POST /users/inventory - YES create a form to list product (OUT)
GET /users/inventory - YES get all form product inventory (OUT)
GET /users/inventory/ idinventory YES get detail form product inventory (outbound)
POST /admins/inventory - YES create a form to list product (IN)
GET /admins/inventory - YES get all form product inventory (IN)
GET /admins/inventory/ idinventory YES get detail form product inventory (inbound)

🛠  Build App & Database

GitHub Visual Studio Code MySQL Go AWS Docker Ubuntu Cloudflare JWT Swagger Postman

🗃️ ERD

Open Api

If you want to consume open api here

Unit Test

Run Locally

Clone the project

https://github.com/ALTA-BE10-HERI/CAPSTONE-MIDDLEMAN

Go to the project directory

cd CAPSTONE-MIDDLEMAN

GitHub Hilmi GitHub Hilmi GitHub Hilmi

(back to top)

©️ 2022

About

No description, website, or topics provided.

Resources

Stars

Watchers

Forks

Releases

No releases published

Packages

No packages published

Languages

  • Go 95.4%
  • HTML 4.5%
  • Dockerfile 0.1%