How joscar05-c/al-toque-delivery works
Al Toque is a food-delivery platform spanning a customer/driver mobile app and web operations consoles for administrators and restaurants. The main customer journey is browsing restaurants and menus, selecting options, checking out, then tracking and reviewing an order; drivers handle delivery, while restaurant and admin consoles manage fulfillment and platform operations. The tree also shows payment, address, application, and profile capabilities. Source excerpts establish selected calls and auth provisioning; links for unsampled workflows are omitted rather than inferred.
Main entry points: page.tsx Admin console · layout.tsx Restaurant portal · _layout.tsx App routing · index.tsx Restaurant discovery
Components 29
Mobile app
- App routing
apps/mobile/src/app/_layout.tsx - Sign-in and profile
apps/mobile/src/app/(auth)/login.tsx - Restaurant discovery
apps/mobile/src/app/(client)/(tabs)/index.tsx - Restaurant menu
apps/mobile/src/app/(client)/restaurant/[id].tsx - Cart state
apps/mobile/src/store/cartStore.ts - Checkout
apps/mobile/src/app/(client)/checkout.tsx - Delivery addresses
apps/mobile/src/lib/addresses.ts - Order lifecycle
apps/mobile/src/lib/orders.ts - Order tracking
apps/mobile/src/app/(client)/order/[id].tsx - Driver workflow
apps/mobile/src/app/(driver)/order/[id].tsx - Driver location
apps/mobile/src/lib/driverLocations.ts - Order reviews
apps/mobile/src/app/(client)/order/review/[order_id].tsx - Profiles and applications
apps/mobile/src/components/ProfileScreen.tsx
Admin operations
- Admin console
apps/web-panel/app/admin/page.tsx - Restaurant administration
apps/web-panel/app/admin/restaurants/actions.ts - Order administration
apps/web-panel/app/admin/orders/actions.ts - Payment review
apps/web-panel/app/admin/payments/actions.ts - User administration
apps/web-panel/app/admin/users/actions.ts - Driver administration
apps/web-panel/app/admin/drivers/actions.ts - Partner applications
apps/web-panel/app/actions/applications.ts
Restaurant operations
- Restaurant portal
apps/web-panel/app/restaurant/layout.tsx - Menu management
apps/web-panel/app/restaurant/menu/actions.ts - Order board
apps/web-panel/app/restaurant/orders/page.tsx
Identity and data
- Web phone auth
apps/web-panel/utils/firebase/auth-client.ts - Profile provisioning
functions/src/index.ts - Firebase identity
- Supabase data
apps/web-panel/utils/supabase/server.ts - Database schema types
packages/shared/types/database.types.ts
Other components
- Customer
Connections 26
- Customer → App routing: opens app
- App routing → Sign-in and profile: routes
- Customer → Restaurant discovery: browses
- Restaurant discovery → Restaurant menu: selects restaurant
- Customer → Checkout: places order
- Checkout → Database schema types: uses types
apps/mobile/src/app/(client)/checkout.tsx - Customer → Order tracking: tracks order
- Driver workflow → Driver location: updates location
- Customer → Profiles and applications: manages profile
- Profiles and applications → Partner applications: submits applications
- Restaurant portal → Menu management: manages menu
- Restaurant portal → Order board: handles orders
- Admin console → Restaurant administration: administers restaurants
- Admin console → Order administration: manages orders
- Admin console → Payment review: reviews payments
- Admin console → User administration: manages users
- Admin console → Driver administration: manages drivers
- Partner applications → Supabase data: submits via RPC
apps/web-panel/app/actions/applications.ts - Web phone auth → Firebase identity: authenticates
apps/web-panel/utils/firebase/auth-client.ts - Firebase identity → Profile provisioning: triggers identity hooks
functions/src/index.ts - Profile provisioning → Supabase data: upserts profile
functions/src/index.ts - Restaurant administration → Admin console: renders in
- Order administration → Admin console: renders in
- Payment review → Admin console: renders in
- User administration → Admin console: renders in
- Driver administration → Admin console: renders in