feat: cleanup, log successful bookings
This commit is contained in:
@@ -97,6 +97,12 @@ class Step4Controller extends AbstractController
|
||||
$this->clearTravelDataCache($bookingCreateDto);
|
||||
$this->bookingService->clearBookingDto($request, BookingDto::MODE_CREATE);
|
||||
|
||||
$this->logger->info('Booking successfully created.', [
|
||||
'date_id' => $bookingCreateDto->travel->id,
|
||||
'hotel_id' => $bookingCreateDto->hotelId,
|
||||
'booking_number' => $bookingResponse->transactionNumber,
|
||||
]);
|
||||
|
||||
return $this->redirectToRoute('app_booking_create_success');
|
||||
} catch (TimeoutException $e) {
|
||||
return $this->handleApiError(
|
||||
@@ -156,10 +162,5 @@ class Step4Controller extends AbstractController
|
||||
// Clear travel data cache (both local and remote variants)
|
||||
$this->cache->delete(sprintf('travel_unified_%d_%d_local', $dateId, $hotelId));
|
||||
$this->cache->delete(sprintf('travel_unified_%d_%d_remote', $dateId, $hotelId));
|
||||
|
||||
$this->logger->info('Cleared travel data cache after successful booking', [
|
||||
'dateId' => $dateId,
|
||||
'hotelId' => $hotelId,
|
||||
]);
|
||||
}
|
||||
}
|
||||
|
||||
Reference in New Issue
Block a user