diff options
| author | Moritz Strohm <strohm@data-quest.de> | 2025-07-23 10:15:42 +0000 |
|---|---|---|
| committer | Moritz Strohm <strohm@data-quest.de> | 2025-07-23 12:20:40 +0200 |
| commit | 4740e3b0314a9efdb057bee9a0c907d108b0abba (patch) | |
| tree | 2373b84c423b95f57e09ef49e2a9beff97666ade /locale | |
| parent | 40331246700acc006525b9f34e4027d68f04aa34 (diff) | |
send delete notification for reservations and lock bookings, too, fixes #4749
Closes #4749
Merge request studip/studip!4376
(cherry picked from commit 8676ca591aae20e87053e22fd40be680c8a3cc36)
65a84077 send delete notification for reservations and lock bookings, too
Co-authored-by: Moritz Strohm <strohm@data-quest.de>
Diffstat (limited to 'locale')
| -rw-r--r-- | locale/de/LC_MAILS/delete_booking_notification.php | 28 | ||||
| -rw-r--r-- | locale/en/LC_MAILS/delete_booking_notification.php | 26 |
2 files changed, 51 insertions, 3 deletions
diff --git a/locale/de/LC_MAILS/delete_booking_notification.php b/locale/de/LC_MAILS/delete_booking_notification.php index c5ef18d..540bbac 100644 --- a/locale/de/LC_MAILS/delete_booking_notification.php +++ b/locale/de/LC_MAILS/delete_booking_notification.php @@ -1,13 +1,37 @@ +<? if (in_array($booking_type, [ResourceBooking::TYPE_NORMAL, ResourceBooking::TYPE_PLANNED])) : ?> <? if ($resource instanceof Room): ?> Ihre Buchung des Raumes <?= $resource->name ?> am <?= date('d.m.Y', $begin) ?> von <?= date('H:i', $begin) ?> bis <?= date('H:i', $end) ?> Uhr wurde gelöscht. -<? else: ?> +<? else : ?> Ihre Buchung der Ressource <?= $resource->name ?> am <?= date('d.m.Y', $begin) ?> von <?= date('H:i', $begin) ?> bis <?= date('H:i', $end) ?> Uhr wurde gelöscht. <? endif ?> +<? elseif ($booking_type == ResourceBooking::TYPE_RESERVATION) : ?> +<? if ($resource instanceof Room): ?> +Ihre Reservierung des Raumes <?= $resource->name ?> am <?= date('d.m.Y', $begin) ?> +von <?= date('H:i', $begin) ?> bis <?= date('H:i', $end) ?> Uhr wurde gelöscht. +<? else : ?> +Ihre Reservierung der Ressource <?= $resource->name ?> am <?= date('d.m.Y', $begin) ?> +von <?= date('H:i', $begin) ?> bis <?= date('H:i', $end) ?> Uhr wurde gelöscht. +<? endif ?> +<? elseif ($booking_type == ResourceBooking::TYPE_LOCK) : ?> +<? if ($resource instanceof Room): ?> +Ihre Sperrbuchung des Raumes <?= $resource->name ?> am <?= date('d.m.Y', $begin) ?> +von <?= date('H:i', $begin) ?> bis <?= date('H:i', $end) ?> Uhr wurde gelöscht. +<? else : ?> +Ihre Sperrbuchung der Ressource <?= $resource->name ?> am <?= date('d.m.Y', $begin) ?> +von <?= date('H:i', $begin) ?> bis <?= date('H:i', $end) ?> Uhr wurde gelöscht. +<? endif ?> +<? endif ?> <? if ($booking_course instanceof Course): ?> -Es handelte sich um eine Buchung für die Veranstaltung <?= $booking_course->getFullname() ?>. +<? if(in_array($booking_type, [ResourceBooking::TYPE_NORMAL, ResourceBooking::TYPE_PLANNED])) : ?> +Es handelte sich um eine Buchung für die Veranstaltung <?= $booking_course->getFullName() ?>. +<? elseif ($booking_type == ResourceBooking::TYPE_RESERVATION) : ?> +Es handelte sich um eine Reservierung für die Veranstaltung <?= $booking_course->getFullName() ?>. +<? elseif ($booking_type == ResourceBooking::TYPE_LOCK) : ?> +Es handelte sich um eine Sperrbuchung für die Veranstaltung <?= $booking_course->getFullName() ?>. +<? endif ?> <? endif ?> <? if ($deleting_user instanceof User) : ?> diff --git a/locale/en/LC_MAILS/delete_booking_notification.php b/locale/en/LC_MAILS/delete_booking_notification.php index 3e57aea..55bbc7e 100644 --- a/locale/en/LC_MAILS/delete_booking_notification.php +++ b/locale/en/LC_MAILS/delete_booking_notification.php @@ -1,3 +1,4 @@ +<? if (in_array($booking_type, [ResourceBooking::TYPE_NORMAL, ResourceBooking::TYPE_PLANNED])) : ?> <? if ($resource instanceof Room): ?> Your booking of the room <?= $resource->name ?> on <?= date('d.m.Y', $begin) ?> from <?= date('H:i', $begin) ?> to <?= date('H:i', $end) ?> has been deleted. @@ -5,9 +6,32 @@ Your booking of the room <?= $resource->name ?> on <?= date('d.m.Y', $begin) ?> Your booking of the resource <?= $resource->name ?> on <?= date('d.m.Y', $begin) ?> from <?= date('H:i', $begin) ?> to <?= date('H:i', $end) ?> has been deleted. <? endif ?> +<? elseif ($booking_type == ResourceBooking::TYPE_RESERVATION) : ?> +<? if ($resource instanceof Room): ?> +Your reservation of the room <?= $resource->name ?> on <?= date('d.m.Y', $begin) ?> +from <?= date('H:i', $begin) ?> to <?= date('H:i', $end) ?> has been deleted. +<? else: ?> +Your reservation of the resource <?= $resource->name ?> on <?= date('d.m.Y', $begin) ?> +from <?= date('H:i', $begin) ?> to <?= date('H:i', $end) ?> has been deleted. +<? endif ?> +<? elseif ($booking_type == ResourceBooking::TYPE_LOCK) : ?> +<? if ($resource instanceof Room): ?> +Your lock booking of the room <?= $resource->name ?> on <?= date('d.m.Y', $begin) ?> +from <?= date('H:i', $begin) ?> to <?= date('H:i', $end) ?> has been deleted. +<? else: ?> +Your lock booking of the resource <?= $resource->name ?> on <?= date('d.m.Y', $begin) ?> +from <?= date('H:i', $begin) ?> to <?= date('H:i', $end) ?> has been deleted. +<? endif ?> +<? endif ?> <? if ($booking_course instanceof Course): ?> -The booking deleted belonged to course <?= $booking_course->getFullname() ?>. +<? if (in_array($booking_type, [ResourceBooking::TYPE_NORMAL, ResourceBooking::TYPE_PLANNED])) : ?> +The deleted booking belonged to course <?= $booking_course->getFullName() ?>. +<? elseif ($booking_type == ResourceBooking::TYPE_RESERVATION) : ?> +The deleted reservation belonged to course <?= $booking_course->getFullName() ?>. +<? elseif ($booking_type == ResourceBooking::TYPE_LOCK) : ?> +The deleted lock booking belonged to course <?= $booking_course->getFullName() ?>. +<? endif ?> <? endif ?> <? if ($deleting_user instanceof User) : ?> |
