From 88a84ed996015aec0ae0f9f1582fd62671910300 Mon Sep 17 00:00:00 2001 From: Julie Lenaerts Date: Mon, 13 Jan 2025 16:16:49 +0100 Subject: [PATCH] Add a logger notice when calendar is canceled --- .../ChillCalendarBundle/Controller/CalendarController.php | 5 +++++ 1 file changed, 5 insertions(+) diff --git a/src/Bundle/ChillCalendarBundle/Controller/CalendarController.php b/src/Bundle/ChillCalendarBundle/Controller/CalendarController.php index 3cd2926e5..08471cd84 100644 --- a/src/Bundle/ChillCalendarBundle/Controller/CalendarController.php +++ b/src/Bundle/ChillCalendarBundle/Controller/CalendarController.php @@ -143,6 +143,11 @@ class CalendarController extends AbstractController if ($form->isSubmitted() && $form->isValid()) { + $this->logger->notice('A calendar event has been cancelled', [ + 'by_user' => $this->getUser()->getUsername(), + 'calendar_id' => $calendar->getId(), + ]); + $calendar->setStatus($calendar::STATUS_CANCELED); $calendar->setSmsStatus($calendar::SMS_CANCEL_PENDING); $this->em->flush();