From 499c84fc5a2137f94c244144784dc26b28553044 Mon Sep 17 00:00:00 2001 From: d1ff1cult0 Date: Fri, 15 Nov 2024 14:22:28 +0100 Subject: [PATCH] Added bijrijden afbraakrit as shift for cantus template --- .../Controller/Admin/CalendarController.php | 11 +++++++++++ 1 file changed, 11 insertions(+) diff --git a/module/CalendarBundle/Controller/Admin/CalendarController.php b/module/CalendarBundle/Controller/Admin/CalendarController.php index 27fc1feb57..b0060d69a2 100644 --- a/module/CalendarBundle/Controller/Admin/CalendarController.php +++ b/module/CalendarBundle/Controller/Admin/CalendarController.php @@ -555,6 +555,17 @@ private function addShiftsByEvent(Event $event) $shiftForm->getHydrator()->hydrate($data) ); + $data['name'] = 'Bijrijden afbraakrit'; + $data['description'] = 'Chillen in de kar. Locatie van de loods is Tervuursevest 238'; + $data['nb_volunteers'] = 2; + $data['nb_volunteers_min'] = 1; + $data['start_date'] = $endDate . ' 01:00'; + $data['end_date'] = $endDate . ' 02:00'; + + $this->getEntityManager()->persist( + $shiftForm->getHydrator()->hydrate($data) + ); + $this->getEntityManager()->flush(); } }