mirror of
https://github.com/Tria-plc/edr-platform.git
synced 2026-09-03 07:23:40 +00:00
A slot can hold a LOADED allocation with no physical wagon backing it — a fleet shortfall can leave a booking's allocation unpinned, and a REAL cut nulls physical_wagon_id without ever touching the slot's own status. Neither buildImportLoadListHtml, buildExportLoadListHtml, nor intercityOnBoardView checked for this: they rendered a ghost row (dash wagon number, but cargo/container info still listed) and counted it toward the Wagons tile. Reproduced live on S-2026-00073: 5 slots (seq 60-64) with no physical wagon, from a booking currently held out for lack of fleet, rendered as phantom rows on the origin doc and every numbered marshalling doc — visible as the Seq column running up to 64 despite only 54 real wagons. All three now additionally require physicalWagonId (or a resolved wagonNumber, for the import doc's already-flattened shape) before a slot gets a row. Added coverage for all three call sites. Co-Authored-By: Claude Sonnet 5 <noreply@anthropic.com>