How laityfaye/terangatable works
This is a multi-tenant restaurant operations SaaS: restaurant staff manage orders and service workflows, while diners discover restaurants, place orders or reservations, and leave reviews. Platform administrators oversee tenant onboarding and moderation. The API exposes domain modules behind tenant-aware authentication and authorization; web route groups indicate dashboard, public restaurant, and marketplace experiences. The tree documents broad capabilities, but many implementations were not sampled, so their connections are shown only as dashed, unverified relationships.
Main entry points: page.tsx Staff dashboard · orders.controller.ts Order handling · prisma.service.ts Tenant-scoped database · tenants.controller.ts Tenant onboarding
Components 26
User experiences
- Staff dashboard
apps/web/src/app/(dashboard)/dashboard/page.tsx - Restaurant site
apps/web/src/app/[slug]/page.tsx - Restaurant marketplace
apps/web/src/app/(marketplace)/decouvrir/page.tsx
Restaurant operations
- Order handling
apps/api/src/modules/orders/orders.controller.ts - Order domain service
apps/api/src/modules/orders/orders.service.ts - Menu management
apps/api/src/modules/menu/products/products.service.ts - Payments
apps/api/src/modules/payments/payments.service.ts - Point of sale
apps/api/src/modules/pos/pos.service.ts - Reservations
apps/api/src/modules/reservations/reservations.service.ts - Delivery
apps/api/src/modules/delivery/delivery.service.ts - Customer loyalty
apps/api/src/modules/crm/customers.service.ts - Order workflows
apps/api/src/modules/workflows/workflow.engine.ts
Public services
- Public review endpoints
apps/api/src/modules/reviews/reviews-public.controller.ts - Review management
apps/api/src/modules/reviews/reviews.service.ts - Marketplace discovery
apps/api/src/modules/marketplace/marketplace.service.ts - Restaurant website settings
apps/api/src/modules/website/website.service.ts
Platform administration
- Tenant onboarding
apps/api/src/modules/tenants/tenants.controller.ts - Regional administration
apps/api/src/modules/regions/regions.service.ts
API foundation
- Authentication
apps/api/src/modules/auth/auth.service.ts - Tenant access control
apps/api/src/common/guards/tenant.guard.ts - Tenant-scoped database
apps/api/src/prisma/prisma.service.ts - Image storage
apps/api/src/modules/storage/storage.service.ts
Other components
- Restaurant staff
- Diners
- Platform admins
- Object storage
Connections 33
- Restaurant staff → Staff dashboard: uses
- Diners → Restaurant site: visits
- Diners → Restaurant marketplace: discovers
- Platform admins → Tenant onboarding: administers
- Staff dashboard → Order handling: manages orders
- Restaurant site → Public review endpoints: reads reviews
- Restaurant site → Menu management: browses menu
- Restaurant marketplace → Marketplace discovery: searches restaurants
- Order handling → Order domain service: delegates to
apps/api/src/modules/orders/orders.controller.ts - Order handling → Order domain service: reads order data
apps/api/src/modules/orders/orders.controller.ts - Order handling → Review management: loads custom fields
apps/api/src/modules/orders/orders.controller.ts - Order handling → Tenant-scoped database: uses domain data
- Order domain service → Tenant-scoped database: reads and writes
- Order handling → Order workflows: runs transitions
- Order handling → Payments: uses payment data
- Public review endpoints → Review management: delegates to
apps/api/src/modules/reviews/reviews-public.controller.ts - Public review endpoints → Tenant-scoped database: looks up tenant
apps/api/src/modules/reviews/reviews-public.controller.ts - Review management → Tenant-scoped database: reads and writes
apps/api/src/modules/reviews/reviews.service.ts - Tenant onboarding → Review management: moderates reviews
apps/api/src/modules/tenants/tenants.controller.ts - Tenant onboarding → Tenant-scoped database: manages tenants
- Restaurant website settings → Image storage: uses uploads
apps/api/src/modules/website/website-dashboard.controller.ts - Image storage → Object storage: stores images
apps/api/src/modules/storage/storage.service.ts - Authentication → Tenant-scoped database: uses identity data
apps/api/src/modules/auth/auth.service.ts - Tenant access control → Tenant-scoped database: enforces tenant scope
- Staff dashboard → Menu management: maintains catalog
- Staff dashboard → Payments: reviews payments
- Staff dashboard → Point of sale: operates register
- Staff dashboard → Reservations: manages bookings
- Staff dashboard → Delivery: dispatches deliveries
- Staff dashboard → Customer loyalty: manages customers
- Diners → Reservations: books tables
- Diners → Order handling: places orders
- Tenant onboarding → Regional administration: assigns regional oversight