Team-facing "open orders" surface. Built as a NS Suitelet (NS-native, customscript_gfs_open_orders, lives in NS menu / portlet on home dashboard) with a Pages mirror at /open-orders.html (D1-backed, faster for mobile / offline). Both reference the same D1 data refreshed every 2 minutes via cron. Three sections render in parallel: open Sales Orders (Pending Fulfillment / Partially Fulfilled / On Hold), open Purchase Orders (Pending Receipt / Partially Received / Pending Bill), open Work Orders (Released / In Progress / Built but Not Closed). Each row shows the customer PO# thread (otherrefnum on SO, memo on PO Path 1, internal req# on PO Path 2, memo on WO — TBD). Inline buttons (approve / hold / escalate) all stage into proposed_actions per ADR-031 — nothing writes to NS directly. Filters across the top: status, customer/vendor, date range, location. LLM-friendly: each section emits JSON-LD WorkflowDefinition markup so chat can ingest the dashboard schema.
customscript_gfs_open_orders (TBD pending Mike approval)/open-orders.html — D1-backed, faster for mobile / offlinePOST /api/open-orders/refresh · rate-limited 1/15s per user(now() - sync_status.last_success_at[transactions]) < 5 minSELECT ... FROM transactions WHERE type IN ('SalesOrd','PurchOrd','WorkOrd') AND status NOT IN ('Closed','Cancelled','Billed','Fully Received','Fully Fulfilled','Built and Closed')otherrefnum.memo (Path 1 SO-connected) or internal req# (Path 2 inventory/build).memo — TBD pending Mike confirmation on whether WO carries it directly.proposed_actions first. Nothing writes to NS directly. Per ADR-031.stage_proposed_action(open_orders_approve) · risk 1stage_proposed_action(open_orders_hold) · risk 2 · prompts hold_reason modalstage_proposed_action(open_orders_escalate) · risk 3 · drafts email via template open_orders_escalationproposed_actions.status → approved · via existing ns_push_queue draineropen_orders.dashboard_loaded · open_orders.row_drilled · open_orders.action_stagedworkflow_run_log (workflow_type = open_orders_suitelet)reflexion_log tagged section_interactions — drives layout iteration<script type="application/ld+json"> WorkflowDefinition + Order entities per section| kind | name | purpose |
|---|---|---|
| D1 table | transactions | SO + PO + WO source records (status NOT closed) |
| D1 table | transaction_lines | per-row item_count + line drill-in |
| D1 table | customer_invoices | SO fulfilled % computation |
| D1 table | item_receipts | PO received % computation |
| D1 table | assembly_builds | WO built % computation |
| D1 table | sync_status | last_success_at per tier — freshness gate |
| D1 table | proposed_actions | HITL queue for approve/hold/escalate row actions |
| D1 table | ns_push_queue | drains approved proposed_actions back to NS |
| D1 table | events | open_orders.dashboard_loaded / .row_drilled / .action_staged |
| D1 table | workflow_run_log | per-load audit row |
| D1 table | reflexion_log | section interaction analytics |
| Workflow contract | open_orders_suitelet | this dashboard · risk 1 · contract_version 2 (migration 135) |
| NS Suitelet | customscript_gfs_open_orders | script id TBD · pending Mike approval |
| Pages mirror | /open-orders.html | D1-backed mobile-friendly mirror |
| Endpoint | POST /api/open-orders/refresh | manual refresh button · rate-limited 1/15s |
| NS field (read) | bodyFields.otherrefnum / memo / status / trandate / total / shipdate | SO PO WO standard fields driving rows |
customscript_gfs_open_orders in NS, plus the deployed Suitelet record. Until then, Pages mirror is the only surface.memo carries the customer PO# (passed from the parent SO on Path 1) or if it lives elsewhere — Mike to confirm.createdby; PO owner is purchasing rep (TBD field); WO owner is production lead (TBD field). Audit pending.On Hold status; PO + WO may need a custbody_hold_flag instead. TBD pending NS field review.