A comprehensive, production-ready business management application designed specifically for South African small to medium businesses, featuring full SARS compliance, POPIA data protection, and real-time inventory management.
- Dashboard: Real-time business overview with KPIs and alerts
- Inventory Management: Stock tracking with automated alerts and barcode support
- Customer Management: POPIA-compliant customer database with account statements
- Sales & Invoicing: SARS-compliant VAT invoicing with automated numbering
- Calendar & Scheduling: Integrated calendar with South African holidays and tax deadlines
- HR Management: Employee records, leave management, and payroll tracking
- Accounting: Chart of accounts, transactions, and financial reporting
- SARS VAT Compliance: 15% VAT calculation and compliant tax invoices
- POPIA Data Protection: Secure customer data handling and privacy controls
- South African Holidays: Pre-loaded public holidays and observances
- Tax Deadlines: Automated reminders for VAT, PAYE, and provisional tax
- Multi-language Support: English, Afrikaans and isiZulu interface options
- Real-time Notifications: Socket.IO powered instant updates
- Responsive Design: Mobile-first design that works on all devices
- Advanced Search: Global search across customers, products, and documents
- Document Sharing: Email, WhatsApp, and download sharing options
- Automated Alerts: Stock level monitoring and management notifications
- Data Export: PDF generation and Excel export capabilities
- Next.js 15 - React framework with App Router
- TypeScript 5 - Type-safe development
- Tailwind CSS 4 - Utility-first styling
- shadcn/ui - High-quality component library
- Framer Motion - Smooth animations and transitions
- Node.js - Server runtime
- Prisma ORM - Database management
- MongoDB Atlas - Cloud database
- Socket.IO - Real-time communication
- NextAuth.js - Authentication system
- React Hook Form + Zod - Form validation
- TanStack Query - Data fetching and caching
- Zustand - State management
- Date-fns - Date manipulation
- Recharts - Data visualization
- Node.js 18+
- MongoDB Atlas account
- Git
- Clone the repository
git clone https://github.com/your-org/account-zero.git
cd account-zero
- Install dependencies
npm install
- Environment Setup
Create a
.env
file in the root directory:
DATABASE_URL="mongodb+srv://username:password@cluster.mongodb.net/accountzero"
NEXTAUTH_SECRET="your-secret-key"
NEXTAUTH_URL="http://localhost:3500"
COMPANY_NAME="Your Company Name"
COMPANY_COUNTRY="ZA"
- Database Setup
# Generate Prisma client
npx prisma generate
# Seed the database
npm run seed-database
npm run seed-products
- Start Development Server
npm run dev
Visit http://localhost:3500
to access the application.
- Build the application
npm run build
- Start production server
npm run server
src/
βββ app/ # Next.js App Router pages
β βββ api/ # API routes
β βββ customers/ # Customer management
β βββ inventory/ # Inventory management
β βββ invoicing/ # Sales and invoicing
β βββ calendar/ # Calendar and scheduling
β βββ hr/ # Human resources
β βββ accounting/ # Financial management
β βββ settings/ # System settings
βββ components/ # Reusable React components
β βββ ui/ # shadcn/ui components
β βββ ... # Custom components
βββ contexts/ # React contexts
βββ hooks/ # Custom React hooks
βββ lib/ # Utility functions
βββ styles/ # Global styles
prisma/
βββ schema.prisma # Database schema
βββ seed.ts # Database seeding
scripts/
βββ seed-database.ts # Database initialization
βββ seed-products.ts # Product data seeding
- Full system access
- User management
- System configuration
- Data export/import
- Security settings
- Business overview dashboard
- All operational modules
- Report generation
- Staff management
- Approval workflows
- Customer management
- Quote and invoice creation
- Order processing
- Customer communications
- Sales reporting
- Stock management
- Purchase orders
- Supplier management
- Stock alerts and reports
- Barcode management
- Employee records
- Leave management
- Payroll processing
- HR reporting
- Compliance tracking
- Personal dashboard
- Basic data entry
- Document viewing
- Calendar access
- Profile management
The application supports multiple languages:
- English (default)
- Afrikaans
Language can be changed using the language selector in the header.
- Real-time Stock Tracking: Automatic updates with every transaction
- Low Stock Alerts: Configurable minimum stock levels with notifications
- Barcode Support: Generate and print barcode labels
- Supplier Management: Track suppliers and purchase orders
- Stock Movements: Complete audit trail of all inventory changes
- POPIA Compliance: Secure data handling with privacy controls
- Account Types: Cash, Credit, and No Account customer types
- Credit Management: Credit limits, payment terms, and aging reports
- Document History: Complete record of all customer transactions
- Communication Tracking: Log all customer interactions
- SARS Compliance: VAT-compliant invoices with proper numbering
- Document Types: Quotes, Invoices, Credit Notes, Delivery Notes
- Automated Numbering: Year-based document numbering system
- Payment Tracking: Record and track customer payments
- Multi-format Export: PDF, Excel, and email delivery
- South African Holidays: Pre-loaded public holidays
- Tax Deadlines: Automated reminders for tax obligations
- Staff Birthdays: Employee birthday tracking
- Company Events: Meetings, deadlines, and important dates
- Multiple Views: Month, week, day, and year views
# Database
DATABASE_URL="mongodb+srv://..."
# Authentication
NEXTAUTH_SECRET="your-secret-key"
NEXTAUTH_URL="http://localhost:3500"
# Company Settings
COMPANY_NAME="Your Company Name"
COMPANY_COUNTRY="ZA"
# Optional Features
ENABLE_NOTIFICATIONS="true"
ENABLE_REAL_TIME="true"
Access company settings through the Settings menu to configure:
- Company information
- Tax settings
- Document templates
- User permissions
- System preferences
- Critical: Out of stock items
- Error: Critically low stock (β€50% of minimum)
- Warning: Low stock (β€minimum stock level)
- Real-time alerts via Socket.IO
- Email notifications for critical events
- Calendar reminders for important dates
- Dashboard widgets for key metrics
- Sales Reports: Revenue, customer analysis, product performance
- Inventory Reports: Stock levels, movements, valuation
- Financial Reports: P&L, Balance Sheet, Cash Flow
- Customer Reports: Aging, statements, communication history
- HR Reports: Employee records, leave balances, payroll
- PDF generation
- Excel spreadsheets
- CSV data export
- Email delivery
- Print-ready formats
- POPIA compliant data handling
- Encrypted data transmission
- Secure authentication
- Role-based access control
- Audit trail logging
- Automated database backups
- Point-in-time recovery
- Data export capabilities
- Disaster recovery procedures
Database Connection Issues
# Check MongoDB connection
npx prisma db pull
Build Errors
# Clear Next.js cache
rm -rf .next
npm run build
Socket.IO Connection Problems
- Check firewall settings
- Verify port 5000 is available
- Ensure WebSocket support
- Check the documentation in
/docs
- Review error logs in the console
- Contact system administrator
- Submit issues via the support portal
- User Manual - Comprehensive user guide
- API Documentation - REST API reference
- Deployment Guide - Production deployment
- Contributing - Development guidelines
This project is licensed under the MIT License - see the LICENSE file for details.
- Fork the repository
- Create a feature branch
- Make your changes
- Add tests if applicable
- Submit a pull request
For support and questions:
- Email: support@accountzero.co.za
- Documentation: docs.accountzero.co.za
- Community: community.accountzero.co.za
Built with β€οΈ for South African businesses
Account Zero - Streamlining business management with local compliance and global standards.