T
Sign in

VALUE-SETS.md — the formal status/dropdown value sets (Phase 1)

VALUE-SETS.md — the formal status/dropdown value sets (Phase 1)

Every fixed-choice column in the schema, its formal set (what the code may write), and the live range observed in data.db (2026-09-06 audit). These sets are the Phase-1 "value set formalized" contract: the app writes only the formal set (code + pins), and any NEW value must be added here first — a missing value here is a spec change, not a code fix.

Orders & contracts (order)

Column Formal set Notes
status open → in-prod → delivered → closed live: open(309)/closed(612) — the mid states arrive with Phase-4 production transitions
type SO · JW · OUTSOURCE · PROD live: JW(915)/SO(6)

Yarn & gatepasses (gatepass)

Column Formal set
kind YARN_IN · YARN_OUT · BEAM_OUT · BEAM_IN · BEAM_REPAIR · BEAM_RETURN · WINDING · DIRECT
direction in · out
status intimated → due → picked → delivered → confirmed → reconciled · (partial is a pick flag)
  • live: delivered/due/intimated; picked/partial appear through the transporter taps.

Beams (beam)

Column Formal set
status floor · getting · onLoom · finished · repair · returned · transfer · cut · in_storage — plus the tippan lifecycle draft · intimated · issued (program beams). NOTE: the tippan set needs an owner/Phase-4 mapping decision — two lifecycles live on one column today (audit).

Rolls (roll)

Column Formal set
grade A · B · C · R · W (W = WIP bucket) — live: A/B/R
status wip · FG · dispatched · reject — live: FG/dispatched/reject

Capture (draft)

Column Formal set
intent lead · quote · order · booking · gatepass · sample · unknown
status new · confirmed · discarded
source forward · snip · notification · manual

Amendments (amendment)

Column Formal set
kind update · delete · reverse · tolerance · jobRate · qty · reassign · transfer — plus allocate (lot allocation, observed in code)

Misc

Column Formal set
party.category Party · Broker · Sizing · Transport · Weaver · Winder · Supplier · OwnUnit · Godown
hishob.status pending · generated · sent · accepted · owner_approved
reconciliation.status pending · approved · exception

Governance

  • New value → edit THIS FILE + the schema comment + the write-site + a pin, in the same commit. The Phase-4 slices (production transitions, checking grades, weft/tppan lifecycles) will extend order.status, beam.status and roll sets here BEFORE their migrations.
  • DB-level CHECK constraints are intentionally NOT applied: import heuristics and legacy myTextile data must keep flowing; the app layer + this doc are the contract (owner-approved, 2026-09-06, Phase-1 verification sheet).