Wholesale Inventory Management System

A comprehensive inventory tracking and stock movement control system for wholesale businesses.

Features

  • Product Management: Add, edit, and categorize products
  • Stock Movement Tracking: Record inbound/outbound stock movements
  • Inventory Control: Real-time stock levels and low stock alerts
  • Supplier Management: Track supplier information and purchase orders
  • Reports: Stock movement history and inventory reports
  • Dashboard: Overview of key metrics and alerts

Project Structure

├── backend/
│   ├── database/
│   │   ├── migrations.ts    # Database schema setup
│   │   └── queries.ts       # Database query functions
│   ├── routes/
│   │   ├── products.ts      # Product CRUD operations
│   │   ├── movements.ts     # Stock movement operations
│   │   ├── suppliers.ts     # Supplier management
│   │   └── static.ts        # Static file serving
│   └── index.ts             # Main Hono app entry point
├── frontend/
│   ├── components/
│   │   ├── App.tsx          # Main React app
│   │   ├── Dashboard.tsx    # Dashboard overview
│   │   ├── ProductList.tsx  # Product management
│   │   ├── StockMovements.tsx # Stock movement tracking
│   │   └── Reports.tsx      # Reporting interface
│   ├── index.html           # Main HTML template
│   └── index.tsx            # Frontend entry point
└── shared/
    └── types.ts             # Shared TypeScript types

Getting Started

  1. The app will automatically set up the database on first run
  2. Navigate to the main URL to access the dashboard
  3. Start by adding products and suppliers
  4. Record stock movements as inventory changes
  5. Monitor stock levels and generate reports

API Endpoints

  • GET /api/products - List all products
  • POST /api/products - Create new product
  • PUT /api/products/:id - Update product
  • DELETE /api/products/:id - Delete product
  • GET /api/movements - List stock movements
  • POST /api/movements - Record stock movement
  • GET /api/suppliers - List suppliers
  • POST /api/suppliers - Create supplier
  • GET /api/dashboard - Dashboard data

Database Schema

  • products: Product information and current stock levels
  • suppliers: Supplier contact and details
  • stock_movements: All inbound/outbound stock transactions
  • categories: Product categorization