Skip to content

Goal: Orders with Lifecycle

Replace the client-side purchase-order sheet with a durable, lifecycle-managed order: a lasting business record that collates production demand into a single-supplier commitment, negotiates that commitment with the supplier through submission and acknowledgment, and reconciles it against materials as they are received. The order becomes a first-class entity with its own history, rather than a screen the buyer assembles and loses when they navigate away.

Today, ordering is a client-side purchase-order sheet (documented in Purchase Orders (Q2 2026)). It works, but the order is not a durable record: its state model is broad, its received amounts are tracked on the header, and there is no lasting, auditable history of how a commitment evolved. This project makes the order a durable entity with a small, well-defined lifecycle, driven by the Demand collation layer beneath it.

  1. An order is a durable, server-side record with full history — who changed what, when.
  2. The order moves through a small, explicit lifecycle — Draft, Submitted, Closed, Canceled — with Confirmed and Receiving shown as computed views, not stored states.
  3. A production request is serviced by at most one open order line at a time (no double-ordering).
  4. After submission, the order’s structure and supplier are frozen; only acknowledgments, receipts, notes, and closure can still be recorded.
  5. Received amounts accrue from actual receiving events and the open amount is computed; the figure reconciles itself and repairs a missed receipt rather than drifting.
  6. Every action is an explicit, attributed act, and a disallowed action is refused with a specific, typed reason.
  • The durable Order and its OrderLines, their lifecycle, and the operations on them.
  • The supplier binding: choose, override, reset while drafting; freeze a snapshot at submission.
  • The demand relationship: order lines service production requests; submission starts production; holds die with the order.
  • Received-quantity reconciliation driven by demand-side production events.
  • No amendment protocol in v1 — out-of-system revisions are recorded as notes rather than a formal versioned-amendment mechanism.
  • Cancel is draft-only — post-submission cancellation is parked for explicit future design.
  • No agreement/release layer — blanket agreements and scheduled releases are not modeled.
  • Money, request-for-quote, kits, and vendor-managed inventory are parked — see the module’s Scope and non-goals.
  • The receiving workflow itself is upcoming — this project provides the reconciliation groundwork the order edge needs, not the receiving clerk’s workflow.
RepositoryRolePlanned changes
operationsBackend serviceNew durable Order/OrderLine module riding the operations component; lifecycle, operations, and the received-quantity reconciliation listener.
arda-frontend-appProduction frontendNet-new order UI (the durable order replaces the client-side sheet); typed-refusal rendering.
documentationDocsThis project, the module reference page, and the derived features and use cases.
  • Orders module — the module reference this project delivers.
  • Design — the reviewed design.
  • Decisions — key decisions and the research behind them.
  • Demand module — the collation layer beneath orders.