page:blueprints:restaurants:inventory manager:django

Restaurants: Inventory Manager Using Django

Summary

A inventory manager blueprint for restaurants built with Django on Ample. Domain schema:

Technical Basis

Public Information

Prerequisites

Workflow Steps

  1. Model the restaurants domain: Create the tables menu_items, stock_movements, orders, order_lines, events. The menu as a sku catalog lives in menu_items; keep the sensitive classes (customer contact and payment details, staff schedules) out of this schema.
  2. Workflow step 1: Model SKUs and stock movements; derive stock from movements.
  3. Workflow step 2: Apply movements transactionally with an optimistic version check on the SKU.
  4. Workflow step 3: Record an event per movement for history.
  5. Workflow step 4: Deploy and verify history and rejected stale updates.
  6. Deploy: Run the synchronous deploy once and read the result. Re-running with no change is a no-op.
  7. Verify: Run the pattern self-test(s) from the example (/p/transactional-workflows) and your own acceptance checks for the restaurants workflow.

Cost Estimate

Limitations

Evidence Summary

Examples