Files
edr-platform/apps/edr-freight-api
Hagernesh c77f5200a3 feat(last-mile): default the approval advance to the live rate
The chief's typed advance was mandatory, so the rule-based estimate shown in
the approve dialog had to be retyped and could silently diverge from it.

advanceAmount is now optional: the advance defaults to the live last-mile
rate estimate (km x rate) and the typed value is only an override. When no
rate covers the job the request is rejected with a message telling the chief
to enter the amount manually, rather than approving a zero advance.

The advance invoice now bills in the rate's currency from the snapshotted
contract summary, falling back to the booking payment currency only when the
amount came from a manual override.

Co-Authored-By: Claude Opus 5 <noreply@anthropic.com>
2026-08-07 11:43:18 +00:00
..
2026-06-29 13:00:55 +00:00
2026-05-12 16:50:18 +03:00
2026-08-05 14:17:00 +00:00
2026-07-16 01:05:57 +00:00
2026-08-05 13:39:45 +00:00
2026-05-12 15:17:16 +03:00