procurement-ingest/lambdas
Adam Moussa 5785f39590 Merge PO revisions and handle out-of-order events
save_revision did a full put_item overwrite, so a revision omitting
line_items/supplier permanently deleted them. save_new_po used a
conditional put that silently dropped the PO when an out-of-order
cancellation had already created a skeleton row.

Switch both to field-level merge update_items: a revision now SETs
only the fields it carries, and a new_po backfills data into a
pre-existing Cancelled skeleton while preserving the Cancelled
status. No email can now delete data established by an earlier one.
2026-06-17 11:37:35 -04:00
..
po Merge PO revisions and handle out-of-order events 2026-06-17 11:37:35 -04:00
wo Validate sender and require Secrets Manager key 2026-06-17 11:37:29 -04:00