A full-stack Point of Sale system for building materials store with bilingual (FR/NL) support.
- 🛒 POS Sales Screen with product search and cart management
- 📄 Document Management (Quotes, Invoices, Receipts, Credit Notes)
- 💳 Payment Processing (Cash, Card, Bank Transfer) with partial payments
- 📊 Sales History with advanced filters
- 💰 Cash Register / Shifts management
- 📦 Inventory tracking with stock movements
- 👥 Customer management
- 🖨️ Professional PDF generation with ALPHA&CO branding
- 🛍️ Shopify integration placeholders
- Frontend: React 19, Tailwind CSS, Shadcn UI
- Backend: FastAPI (Python), Motor (async MongoDB)
- Database: MongoDB
- PDF Generation: ReportLab
- Node.js: v18 or higher (Download)
- Python: v3.10 or higher (Download)
- MongoDB: v6 or higher (Download)
- Yarn:
npm install -g yarn
git clone <repository-url>
cd alphaco-posOption A: Install All at Once (Recommended)
npm run install:allOption B: Install Separately
# Backend
cd backend
pip install -r requirements.txt
# Frontend
cd frontend
yarn installBackend:
cd backend
cp .env.example .env
# Edit .env with your MongoDB connection string if neededFrontend:
cd frontend
cp .env.example .env
# Edit .env if you need to change the backend URLmacOS (with Homebrew):
brew services start mongodb-communityWindows:
net start MongoDBLinux:
sudo systemctl start mongodOption A: Run Both Servers Together (Recommended)
npm run devThis starts:
- Backend: http://localhost:8001
- Frontend: http://localhost:3000
Option B: Run Separately
Terminal 1 - Backend:
cd backend
uvicorn server:app --reload --host 0.0.0.0 --port 8001Terminal 2 - Frontend:
cd frontend
yarn startOpen your browser and navigate to:
- Frontend: http://localhost:3000
- Backend API: http://localhost:8001/api/
- API Docs: http://localhost:8001/docs
alphaco-pos/
├── backend/
│ ├── server.py # FastAPI application
│ ├── requirements.txt # Python dependencies
│ └── .env # Backend configuration
├── frontend/
│ ├── src/
│ │ ├── pages/ # React pages
│ │ ├── components/ # Reusable components
│ │ └── utils/ # Helper functions
│ ├── package.json # Node dependencies
│ └── .env # Frontend configuration
└── package.json # Root scripts for easy dev
npm run install:all- Install all dependencies (backend + frontend)npm run dev- Start both servers concurrentlynpm run dev:backend- Start backend onlynpm run dev:frontend- Start frontend onlynpm run build- Build frontend for production
cd frontend
yarn start # Development server
yarn build # Production build
yarn test # Run tests
yarn lint # Lint codecd backend
uvicorn server:app --reload # Development
uvicorn server:app --host 0.0.0.0 --port 8001 # ProductionThe application uses mock data for initial testing. No authentication is required.
If port 8001 or 3000 is already in use:
Backend (8001):
# macOS/Linux
lsof -ti:8001 | xargs kill -9
# Windows
netstat -ano | findstr :8001
taskkill /PID <PID> /FFrontend (3000):
# macOS/Linux
lsof -ti:3000 | xargs kill -9
# Windows
netstat -ano | findstr :3000
taskkill /PID <PID> /F-
Check MongoDB is running:
# macOS/Linux ps aux | grep mongod # Windows sc query MongoDB
-
Verify connection string in
backend/.env:MONGO_URL=mongodb://localhost:27017 DB_NAME=alphaco_pos
If you encounter peer dependency conflicts:
cd frontend
rm -rf node_modules package-lock.json
yarn installThe project uses date-fns@^3.6.0 which is compatible with react-day-picker@8.10.1.
If Python modules are missing:
cd backend
pip install -r requirements.txt --force-reinstallIf PDF generation fails, ensure reportlab is installed:
cd backend
pip install reportlab pillowMONGO_URL=mongodb://localhost:27017 # MongoDB connection
DB_NAME=alphaco_pos # Database name
PORT=8001 # Server port
HOST=0.0.0.0 # Server host
CORS_ORIGINS=http://localhost:3000 # Allowed originsREACT_APP_BACKEND_URL=http://localhost:8001 # Backend API URLcd frontend
yarn buildThis creates an optimized build in frontend/build/.
For production, run with Gunicorn or similar:
cd backend
gunicorn server:app --workers 4 --worker-class uvicorn.workers.UvicornWorker --bind 0.0.0.0:8001- Product search and category filtering
- Cart management with quantity and discounts
- Customer selection
- Multiple payment methods
- Save as quote (no stock impact)
- Complete sale with PDF receipt
- View all past sales
- Filter by date range, status, payment method, channel
- Reorder (load items back to cart)
- Process returns
- Download PDFs
- View all document types (Quotes, Invoices, Receipts, Credit Notes)
- Filter by type and status
- Convert quotes to invoices
- Download PDFs with proper filenames (FACTURE_XXX.pdf)
- Payment actions
- Professional A4 layout with ALPHA&CO branding
- Vendor and client boxes
- Line items table
- VAT breakdown
- Payment history
- Print and PDF download
- Partial payments support
- Open/close shifts
- Track cash movements
- Generate Z reports
- View stock levels
- Track stock movements
- Low stock alerts
For issues or questions, please contact support@alphaco.be
MIT License - See LICENSE file for details