# Eniceberny Bakery & Culinary Hub Platform Documentation

Welcome to the official technical, architectural, operational, and user documentation for the **Eniceberny Bakery & Culinary Hub** platform.

This platform powers a multi-channel artisan bakery, culinary kitchen, and hospitality enterprise in Ghana — seamlessly unifying consumer storefront e-commerce, in-store Point of Sale (POS) counter terminals, corporate catering quotation workflows, real-time financial ledgers, and cash drawer reconciliation.

---

## 🎯 Platform Mission & Core Capabilities

Eniceberny Bakery & Culinary Hub provides a unified digital ecosystem serving four distinct constituencies:

1. **Patrons & Corporate Clients**: Browse artisan bread, gourmet pastries, continental dishes, authentic Ghanaian delicacies, and celebratory cakes with seamless Mobile Money (MTN & Telecel) and card checkout.
2. **In-Store Staff & Cashiers**: High-speed Point of Sale (POS) terminal with instant search, portion selection, quick cash tenders, and thermal receipt generation.
3. **Kitchen Chefs & Dispatchers**: Real-time order fulfillment display, portion tracking, holding temperature protocols, and courier handoff checklists.
4. **Operations & Executive Leadership**: Centralized administrative console overseeing orders, multi-channel ledgers, catering proposals, inventory valuations, automated audit trails, and modular CMS branding.

---

## 🗺️ Documentation Map

The documentation is organized into six structured domains:

### 👥 User Guides & Operations
* [**Staff Training & Standard Operating Procedures (SOP)**](staff-training.md): Operational manual for Cashiers, Kitchen Dispatchers, Catering Event Crew, and Shift Supervisors.
* [**Patron & Client User Manual**](customer-guide.md): Customer guide for online ordering, bespoke cakes, Mobile Money checkout, order tracking, and invoice payments.
* [**Point of Sale (POS) Counter**](pos.md): High-speed counter register, portion selections, Dine-in vs Takeaway modes, quick cash keys, and thermal receipts.
* [**Administration Panel & Operations**](admin.md): Executive sales metrics, order fulfillment pipelines, customer rosters, modular settings cards, and audit logs.
* [**Accounts, Financial Ledgers & User Identity**](accounts.md): Customer account self-service, staff RBAC provisioning, cash drawer balancing, MoMo reconciliation, and CSV financial exports.
* [**System Troubleshooting & Incident Runbooks**](troubleshooting.md): Step-by-step diagnostic and remediation protocols for cashiers, dispatchers, admins, customers, and DevOps.

### 🏗️ Architecture & Core Engineering
* [**Platform Architecture & Multi-Channel ERP**](architecture.md): System topography, Laravel 11/12 foundation, service layer architecture, and design decisions.
* [**Developers & Maintainers Handbook**](developer-handbook.md): Technical handbook for future developers, coding standards, design patterns, and debugging runbooks.
* [**Database & Storage Engine**](database.md): Entity relationship diagrams, schema definitions, indexing strategies, and transactional locking.
* [**Security & Ghana Compliance**](security.md): CIA triad enforcement, role-based access control (RBAC), and Ghana Data Protection Act 2012 (Act 843) compliance.

### 🛍️ Storefront & Digital Commerce
* [**REST API (v1) & Web Endpoints**](api.md): Public and internal API specifications, cart drawer endpoints, and payload contracts.
* [**Payment Systems & MoMo Gateways**](payments.md): Multi-gateway architecture (Cash, MTN MoMo, Telecel Cash, Paystack), webhook cryptographic HMAC verification, and PDF invoice generation.
* [**Catering & Event Quotations**](catering.md): Event inquiry management, banquet packages, custom quotation builder, and automated order conversion.

### 🎨 Content, Media & SEO
* [**Content Management & Dynamic CMS**](cms.md): Zero-code homepage section reordering, marketing banners, testimonials, FAQs, and Schema.org SEO.
* [**Media Asset Management**](media.md): Secure image uploads, brand logo engine, optimization, and catalog associations.

### 🚀 DevOps & Quality Assurance
* [**Automated Testing & QA Guide**](testing.md): Automated 85-test PHPUnit test suite, in-memory SQLite fixtures, CI/CD pipeline, and assertions guide.
* [**Docker & Render Deployment**](deployment.md): Multi-stage container builds, Apache configuration, Render PaaS blueprint, and post-deploy seeding.

---

## 💻 Core Technology Stack

| Layer | Technologies | Key Responsibilities |
| :--- | :--- | :--- |
| **Backend Framework** | **Laravel 11/12 (PHP 8.4)** | Business services, routing, validation, security middleware, mail engine |
| **Frontend Rendering** | **Blade + Alpine.js** | Server-rendered luxury UI with reactive client-side micro-interactions |
| **Styling & Design System** | **Tailwind CSS v3** | Warm luxury palette (Cream `#F6F3EC`, Deep Burgundy `#4A1521`, Gold `#C29B38`) |
| **Database** | **PostgreSQL 16 / SQLite** | Relational transactions, JSON fields, ACID compliance, in-memory CI testing |
| **Asset Bundler** | **Vite** | Lightning-fast asset compilation, tree-shaking, production minification |
| **Document Engine** | **DomPDF + php-qrcode** | Formal customer receipts, quote printouts, offline QR code embedding |
| **Containerization** | **Docker (PHP 8.4 Apache)** | Production runtime, multi-stage builder, health check probes (`/up`) |
| **CI / CD Automation** | **GitHub Actions** | Automated testing matrix (PHP 8.4, Node 20), build validation, deploy hooks |

---

## ⚡ Quick Start for Developers

Clone the repository and spin up the development environment in minutes:

```bash
# 1. Clone repository
git clone https://github.com/mhiskall282/enicebakery-website.git
cd enicebakery-website

# 2. Install PHP and Node dependencies
composer install
npm install

# 3. Configure environment
cp .env.example .env
php artisan key:generate

# 4. Run migrations and seed operational data
php artisan migrate --seed

# 5. Build frontend assets and run local dev server
npm run dev
php artisan serve
```

Run the complete automated test suite:

```bash
php artisan test
```

> [!TIP]
> **Production Credentials**: The initial administrative superuser is seeded as `admin@enicebakerygh.com` with password `password`. In production, update this password immediately upon first deployment.
