Point of Sale (POS) system with a React (Vite) frontend and a Node.js (Express).
The frontend also includes Electron integration for desktop usage.
- POS & Checkout
- Product selection, cart management, and invoice/receipt flow.
- Inventory
- Products, categories, brands, units, and stock management.
- Sales & Purchases
- Sales, purchases, suppliers, and invoices.
- Reports
- Sales report, purchase report, customer report, customer due report.
- Multi-page App
- Frontend routes for dashboard, POS, products, categories, brands, units, customers, suppliers, etc.
Clone this repository:
git clone https://github.com/abdulbasit56/DBs.git
cd DBsThis repo contains two apps:
backend/andfrontend/.
cd backend
npm install
npm run devIn another terminal:
cd frontend
npm install
npm run dev -- --hostThe backend connects to MongoDB using Mongoose.
Create backend/.env and set:
MONGODB_URI="your_mongodb_connection_string"## Technology Stack### Frontend
- **React** (Vite)
- **react-router-dom**
- **Tailwind CSS** (+ `@tailwindcss/vite`)
- **daisyUI**
- **MUI (Material UI)** (`@mui/material`, `@mui/icons-material`, `@mui/x-data-grid`)
- **@tanstack/react-table**
- **jsPDF** + **xlsx** (exports)
- **Electron integration** (`electron.js`, `preload.js`)
### Backend
- **Node.js** + **Express**
- **Sequelize** (ORM)
- **MongoDB**
- **jsonwebtoken**, **bcrypt**
- **multer** (uploads)
- **express-session**
- **dotenv**, **cors**## Project Structure```textDBs/├── backend/│ ├── .env│ ├── package.json│ └── src/│ ├── config/│ ├── middleware/│ ├── models/│ ├── routes/│ ├── services/│ ├── utils/│ ├── index.js│ ├── initialData.js│ └── seed.js├── frontend/│ ├── build/│ ├── public/│ ├── src/│ │ ├── assets/│ │ ├── components/│ │ ├── context/│ │ ├── hooks/│ │ ├── pages/│ │ ├── services/│ │ ├── App.jsx│ │ ├── main.jsx│ │ └── index.css│ ├── electron.js│ ├── preload.js│ ├── index.html│ ├── package.json│ └── vite.config.js└── README.md- Dashboard:
/ - POS:
/pos - Products:
/products, add product:/add-product - Categories:
/categories, add:/add-category - Brands:
/brands, add:/add-brand - Units:
/units, add:/add-unit - Customers:
/customers, add:/add-customer - Suppliers:
/suppliers, add:/add-supplier - Invoices:
/invoices - Sales:
/sales, add:/add-sale, return:/sales-return - Purchases:
/purchases, add:/add-purchase - Reports:
/sales-report,/purchase-report,/customer-report,/customer-due-report - Auth:
/signin,/signup
- Fork the repository
- Create your feature branch (
git checkout -b feature/new-feature) - Commit your changes (
git commit -am 'Add new feature') - Push to the branch (
git push origin feature/new-feature) - Open a Pull Request
MIT License - see LICENSE for details.
