Egg distribution and sales management system
Version: 1.0.0
Last Updated: February 2026
EggBucket is a full-stack web application for managing egg distribution operations including sales tracking, payments, outlet management, and reporting. Built with React + Vite frontend and Express.js backend with Firebase integration.
- Dashboard - Overview of sales, damages, and distribution metrics
- Daily Sales - Track and manage daily egg sales
- Daily Damages - Record and monitor damaged inventory
- NEC Crate Management - Track crate inventory and movements
- Cash Payments - Manage cash payment transactions
- Digital Payments - Handle digital/online payments
- Distribution - Manage distributor operations
- Outlets - Outlet registration and management
- Reports - Generate and export reports (Excel)
- User Management - Role-based access control (Admin, Supervisor, Data Agent, Viewer)
- React 19
- Vite 7
- React Router DOM 7
- Tailwind CSS 4
- Recharts (analytics charts)
- XLSX (Excel export)
- FontAwesome icons
- Node.js / Express 5
- Firebase Admin SDK
- JWT Authentication
- bcryptjs (password hashing)
EggBucket/
├── src/ # Frontend source
│ ├── components/ # Reusable UI components
│ ├── pages/ # Page components
│ ├── layouts/ # Layout wrappers
│ ├── context/ # React context providers
│ └── utils/ # Utility functions
├── backend/ # Backend API
│ ├── controllers/ # Route handlers
│ ├── routes/ # API routes
│ ├── config/ # Firebase config
│ └── scripts/ # Utility scripts
├── public/ # Static assets
└── scripts/ # Build scripts
- Node.js 18+
- Firebase project with Firestore
# Install dependencies
npm install
# Start development server
npm run dev
# Build for production
npm run build
# Preview production build
npm run previewcd backend
# Install dependencies
npm install
# Start server
node server.js
# Or with nodemon (development)
npx nodemon server.jsPORT=5000
JWT_SECRET=your_jwt_secret_key
FIREBASE_PROJECT_ID=your_firebase_project_idPlace your serviceAccountKey.json in backend/config/
| Role | Access |
|---|---|
| Admin | Full access to all features |
| Supervisor | Zone-based outlet and sales management |
| Data Agent | Limited access based on assigned roles |
| Viewer | Read-only access to data |
| Route | Description |
|---|---|
/api/auth |
Authentication |
/api/admin |
Admin operations |
/api/outlets |
Outlet management |
/api/dailysales |
Daily sales data |
/api/daily-damage |
Damage records |
/api/cash-payments |
Cash payments |
/api/digital-payments |
Digital payments |
/api/distributors |
Distributor data |
/api/neccrate |
Crate management |
/api/reports |
Report generation |
- Build:
npm run build - Deploy
dist/folder - Set environment variables if needed
- Upload
backend/folder - Set environment variables
- Start command:
node server.js - Ensure Firebase credentials are configured
| Version | Date | Changes |
|---|---|---|
| 1.0.0 | Feb 2026 | Initial release with full feature set |
Private / Internal Use