1. Overview
The platform is architected in two layers:
app/Core— the stable e-commerce domain: products, orders, cart, coupons, shipping, media, customers, settings, courier integration, widgets.app/Modules— 16 self-contained, service-provider-registered modules (each with its ownmodule.jsonmanifest, routes, models, and services) that extend the core without modifying it.
This gives the codebase a WordPress/WooCommerce-style extensibility model while keeping the core lean and testable.
2. Technology Stack
Backend & framework
- Laravel 12 (PHP 8.2+)
- Laravel Sanctum — token/session API authentication
- Barryvdh DomPDF — invoice & document PDF generation
- Intervention Image v3 — image processing / responsive variants
- Blade Lucide Icons — icon set
- Event/Listener + Queue/Jobs architecture for async work (courier dispatch, mail)
Storefront frontend
- Blade templating (server-rendered pages)
- Alpine.js (+ collapse, focus, intersect plugins) for interactivity
- Tailwind CSS 3 with the Typography plugin (dedicated
tailwind.storefront.config.js) - Swiper for sliders/carousels
- Vite build pipeline
Admin frontend
- Standalone React SPA (React Router) built externally and deployed as static assets into
public/admin/; all admin operations run through the REST API.
Tooling & QA
- PHPUnit 11, Mockery, Faker for tests
- Laravel Pint (code style), Pail (log tailing), Sail (Docker), Collision
3. Storefront Features (customer-facing)
Server-rendered, SEO-friendly pages driven by dedicated Storefront controllers:
- Home page — widget-driven, fully configurable layout (hero sliders, featured products, category grids, brand strips, testimonials, promotions).
- Shop / product listing — filterable, sortable catalog browsing.
- Product detail — variations, image gallery, related products, upsells & cross-sells, reviews & ratings, SEO meta.
- Category / Collection / Brand pages — including curated collections, smart (rule-based) collections, and a brand classifier/directory with "top brand" highlighting.
- Product groups — top-level departments (e.g. Skincare, Makeup) mapped to categories and brands.
- Search — live search suggestions endpoint (
/search/suggest) plus full search results. - Cart — guest & authenticated carts, quantity updates, coupon application.
- Checkout — guest checkout supported; geo-aware address dropdowns (country → state → district), live shipping calculation, coupon redemption.
- Order confirmation & order tracking — public tracking by order number.
- Wishlist — works for both guests and logged-in users, with merge-on-login and "move to cart".
- Deals / Promotions — dedicated deals hub and per-promotion landing pages.
- Blog — posts, categories, tags, author profiles, and inline product embeds.
- FAQ — searchable, tagged FAQ section.
- Dynamic CMS pages — DB-driven static pages via a catch-all slug route.
- Customer account area — profile, password change, saved addresses, order history.
- Authentication — register, login, logout, forgot/reset password (code-based).
- Newsletter — rate-limited subscribe form with admin-side subscriber management and export.
4. Admin Panel Features (React SPA + REST API)
The admin is a React SPA backed by a comprehensive, permission-gated REST API.
Catalog management
- Products — full CRUD, variations, soft-delete + trash/restore/force-delete, bulk trash, upsells/cross-sells, media attachment, SEO meta.
- Product variations — dedicated variant CRUD.
- Categories — CRUD, bulk update/delete, hierarchy, SEO fields, flags.
- Brands — CRUD, bulk operations, parent hierarchy, "top brand" & classifier flags.
- Attributes & attribute values — richer metadata, filterable attributes, swatch/image values.
- Tags & product groups.
- Media library — upload, edit, responsive-variant regeneration (single & bulk).
Order management
- Orders — listing, detail, status workflow, bulk trash/restore/delete, empty trash.
- Order notes (internal & customer-facing).
- Shipments — create/update, tie to courier consignments.
- Refunds — customer-requested and admin-issued, with line-item refunds.
- Invoices — PDF download & regeneration.
- Transactional email — preview and send order emails per order.
- Available shipping methods per order.
Marketing & merchandising
- Coupons — CRUD, advanced rules, bulk generation, coupon batches, validation, duplication, usage tracking.
- Campaigns — time-limited promotions (flash sales, BOGO, seasonal).
- Bundles — sell multiple products together at a discount.
- Widgets & widget zones — a page-building system (registry of widget types, drag/reorder, zone assignment) that powers the storefront layout.
- Menus & mega menus — rich navigation configuration.
- Sliders / testimonials — managed content blocks.
Customers & staff
- Customers — listing, stats, detail, status toggling, admin password reset.
- Admin users — CRUD (admin-only), role-based access (
manage,admin-only). - Login activity log — security auditing of admin sign-ins.
Store configuration
- Settings — grouped key/value store, public vs. protected settings.
- Email templates — customizable transactional templates with preview.
- Shipping zones — zones, locations, and methods (incl. weight-based rates).
- Geo locations — manage the country/state/district hierarchy with reordering.
- Pages — CMS page CRUD.
Dashboard & analytics
- Customizable dashboard — saved per-user layouts, a widget registry, and per-widget data endpoints.
- Analytics events — public, throttled event ingestion for behavioral tracking.
5. Bangladesh Market Integrations
A key differentiator is deep localization for the Bangladeshi e-commerce market:
- Courier integrations — pluggable courier providers with two built-in implementations:
- Pathao Courier module
- Steadfast Courier module
Managed through a CourierManager with a common CourierProviderContract, supporting: consignment creation (auto-dispatched via queued jobs on order events), balance checks, bulk send, status polling, print/label details, and inbound webhooks (rate-limited) for status updates.
- Fraud check service — courier-backed customer fraud/return-rate lookups before shipping.
- Courier logging — every provider call is logged and auditable in the admin.
- Geo hierarchy — country → state/division → district data model powering checkout address selection and shipping-zone matching.
- COD / BDT-oriented workflows — order and pricing services model integer minor-unit amounts with exchange-rate support, suited to cash-on-delivery.
6. Modular Architecture
Sixteen feature modules under app/Modules, each with its own service provider and module.json manifest:
| Module | Purpose |
|---|---|
| Blog | Posts, categories, tags, author profiles, SEO, product embeds |
| Bundles | Sell multiple products together at a discounted price |
| Campaigns | Time-limited promos: flash sales, BOGO, seasonal discounts |
| Collections | Curated product collections |
| SmartCollections | Rules engine for auto-populated collections |
| ProductGroups | Top-level departments mapped to categories & brands |
| FAQ | FAQ management with rich content, tagging, search |
| MegaMenu | Rich mega-menu layouts for navigation items |
| Navigation | Enhanced admin capabilities for the core menu system |
| PageTemplates | CMS-like page templates with structured sections/fields |
| Reviews | Admin moderation for product reviews & ratings |
| Sliders | Managed hero/promo sliders |
| Testimonials | Customer testimonial blocks |
| PathaoCourier | Pathao courier provider integration |
| SteadfastCourier | Steadfast courier provider integration |
| WooMigration | WooCommerce import/export migration tooling |
The WooMigration module notably supports migrating an existing WooCommerce store into the platform — a practical onboarding path from WordPress.
7. Core Domain Services
The app/Core/Services layer encapsulates business logic away from controllers:
- CartService — guest & authenticated cart lifecycle.
- PricingService / PricingHelper — price resolution, sales, minor-unit math.
- CouponService (+
DiscountBreakdown,ValidationResult) — coupon validation and discount computation. - OrderService / OrderNoteService — order creation and note management.
- RefundService — refund processing with line items.
- Shipping (
ShippingManager,ShippingCalculator,ManualProvider) — zone/method resolution and rate calculation. - Courier (
CourierManager,FraudCheckService) — provider orchestration. - Media (
MediaService,ImageProcessor) — uploads & responsive variants. - Seo (
SeoService,SeoData) — centralized SEO meta via aHasSeoMetatrait. - Widget (
WidgetRegistry,WidgetResolver) — storefront page composition. - Invoice (
InvoiceService) — DomPDF invoice generation. - Mail / PasswordReset / Settings / Wishlist / Tracking services.
Cross-cutting concerns use Laravel's events & listeners (e.g. OrderPlaced → auto-create courier shipment via a queued job) and mailables (OrderTemplateMail, PasswordResetCodeMail).
8. Security & Access Control
- Sanctum authentication for the API; session auth for the storefront.
- Layered authorization gates: public endpoints,
auth:sanctum,can:manage(store staff), andcan:admin-only(settings, email templates, admin users). - Rate limiting / throttling on sensitive public endpoints (newsletter, analytics ingestion, order tracking, refund requests, courier webhooks).
- Login activity auditing for admin accounts.
- Code-based password reset flow.
- Soft deletes with trash/restore across products and orders to prevent accidental data loss.
9. Notable Engineering Highlights
- Headless-ready core — the same REST API that powers the React admin could drive a mobile app or alternate frontend.
- Widget-driven storefront — non-technical staff can recompose home and landing pages from admin-managed widget zones, no deploys required.
- Pluggable providers — courier and shipping providers implement contracts, making new integrations additive.
- Two-tier build — separate Vite/Tailwind config for the storefront, with the admin SPA built and deployed independently into
public/admin. - Migration path — WooCommerce import lowers the switching cost for an existing WordPress-based store.
10. Deployment
- Ships with a manual cPanel deployment checklist (
DEPLOY.md) plus adeploy/directory of assets. - Operational note: after a manual upload, the bootstrap cache must be cleared or the site returns HTTP 500 (the CLI path continues to work).
- Admin SPA note: the admin UI is a separate source project; updating it means rebuilding that project and copying its
distoutput intopublic/admin.
This case study was generated from a survey of the codebase (routes, models, controllers, services, modules, and migrations) and reflects the platform's implemented feature set.



