fix: platform decrease usage when cancelling booking (#18241)

* fix: decrement billing upon cancelled booking

* docs: explain billing in FAQ

* update docs
This commit is contained in:
Lauris Skraucis authored and GitHub committed 2024-12-18 14:50:31 +02:00
1 parent ad5d92dff0
commit e6a7ae7da3
2 files changed
+12 -1

No files matched your search

@@ -340,7 +340,10 @@ export class BookingsService_2024_08_13 {
}
const bookingRequest = await this.inputService.createCancelBookingRequest(request, bookingUid, body);
await handleCancelBooking(bookingRequest);
const res = await handleCancelBooking(bookingRequest);
if (!res.onlyRemovedAttendee) {
await this.billingService.cancelUsageByBookingUid(res.bookingUid);
}
if ("cancelSubsequentBookings" in body && body.cancelSubsequentBookings) {
return this.getAllRecurringBookingsByIndividualUid(bookingUid);