mirror of
https://github.com/Tria-plc/edr-platform.git
synced 2026-09-07 15:25:45 +00:00
The receive drawer captured one truck per arrival, so a customer whose containers came on three trucks had to be received three times over. Stage trucks instead. "Add another truck" validates the form exactly as a single-truck receive does, files the truck with its own plate, driver and containers, and clears the form for the next one. The staged trucks are listed above the form with their boxes, each removable, and the arrival is received in one operation. Containers already staged on an earlier truck drop out of the picker, so the same box cannot be sent twice. Receiving with a part-filled form and trucks already staged is treated as the operator still typing rather than a finished arrival: it asks them to finish or clear the truck instead of silently dropping what they entered. An untouched form receives just the staged trucks. With no trucks staged the drawer sends the original truckEntrance and containerNumbers fields, so a single-truck arrival takes exactly the path it did before. Verified: backoffice type-check reports 982 errors both with and without this change (all pre-existing, none in the touched files); 13 warehouse API suites pass (73 tests). Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>