fix(reservations): link a cost created on a booking update on its insert

syncBudgetOnUpdate created the expense and then set its reservation_id in a
second statement, inside a try that logs and swallows the failure. Running
inside updateWithCost, a failed back-link committed an expense that was not
linked to its booking. The expense is now created through
linkBudgetItemToReservation, which writes the link on the insert, the same
way syncBudgetOnCreate does.
This commit is contained in:
Maurice
2026-10-08 15:56:18 +02:00
parent b84867b4c2
commit c7feaf0a65
3 changed files with 10 additions and 11 deletions
+1 -1
View File
@@ -17,7 +17,7 @@
"src/nest/places/places.service.ts": 2020,
"src/nest/plugins/plugin-runtime.service.ts": 1463,
"src/nest/plugins/runtime/plugin-sdk.ts": 1094,
"src/nest/reservations/reservations.service.ts": 1248,
"src/nest/reservations/reservations.service.ts": 1247,
"src/nest/trips/trips.service.ts": 1013,
"src/nest/vacay/vacay.service.ts": 1440
}