Restaurant Setup Phase 2
Phase 2 adds the tenant-local setup suite for paid restaurants: outlets, floors, animated table maps, table states, kitchen stations, branch settings, staff, and SaaS plan-limit enforcement.
Access
Restaurant setup is available only after tenant login and
an active paid subscription. Use
/r/{tenant}/setup for the command center.
Unpaid, expired, suspended, cancelled, or provisioning
failed tenants are redirected to the subscription pending
page before setup routes are reached.
Setup Command Center
The setup dashboard shows animated KPI cards, setup
progress, branch health, plan usage meters, visual
readiness, station coverage, staff assignment coverage,
and quick actions for branches, floor design, staff, and
receipts.
It uses shared Blade components, x-ui.page-header,
the table usage pattern, appSwal, and
appToast.
Visual Setup Lab
Open the stateful visual setup lab from
/r/{tenant}/floors/{floor}/lab. The lab is a
setup-only workspace for tables, floor objects, templates,
snapshots, and visual quality warnings. It does not create
POS orders, KDS tickets, QR ordering, inventory, or reports.
- Floor objects support walls, doors, windows, counters, service zones, decor markers, labels, dividers, and furniture.
- Objects are stored in
floor_layout_objectsand do not count against SaaS table limits. - Snapshots are stored in
floor_layout_snapshotswith table/object payloads, version metadata, and restore support. - Presets include compact cafe, full-service restaurant, food court outlet, patio dining, bar layout, and banquet layout.
- The lab shell includes palette, toolbar, zoom/pan, grid control, inspector, layer list, minimap, warnings, and snapshot restore points.
- State-changing actions use the shared confirm Swal, loading Swal, and
appToastresult pattern.
Floor Designer
The classic designer remains available at
/r/{tenant}/floors/{floor}/designer, while
the Visual Setup Lab is now the preferred design surface.
Both canvases use vanilla JavaScript plus local
Interact.js assets for drag, resize, grid snapping, zoom
controls, animated status changes, station color bands,
capacity badges, and table hover details.
- Supported table shapes: round, square, rectangle, booth, bar seat, and patio.
- The generator accepts ranges like
A1-A20with capacity, shape, spacing, columns, and station. - Layout saves are versioned. A stale save returns a conflict and the UI asks the user to reload.
- Table positions and visual objects must stay inside floor bounds before a save is accepted.
- Overlapping tables and missing access markers are warnings, not blockers.
- Plan table limits are enforced before manual creates, generator creates, and template application.
Branches And Settings
Branches store outlet metadata, timezone, service modes, default currency, receipt profile, and status. Default branches are protected from archive. Branch settings cover tax percentage, service charge mode and value, receipt header/footer, and kitchen ticket printer placeholders.
Kitchen Stations And Staff
Kitchen stations belong to branches and support type, color, prep target minutes, status, printer metadata, table assignment, and staff assignment. Tenant staff CRUD uses tenant-local users with Owner, Manager, Cashier, Waiter, Kitchen, and Host roles.
- Owner receives all setup permissions during provisioning.
- Manager receives setup management permissions.
- Cashier, Waiter, Host, Kitchen, and Staff receive scoped setup access.
- Staff invites are sent through the configured mailer and work with Mailpit or log mail.
Plan Limits
The setup suite reads the tenant subscription plan and blocks over-limit active branch, table, and non-owner staff creation or reactivation. Starter allows 1 branch, 20 tables, and 10 staff. Growth allows 3 branches, 80 tables, and 35 staff. Pro allows 10 branches, 250 tables, and 100 staff.
Verification
php artisan test
php artisan route:list --path='r/'
npm run build