summaryrefslogtreecommitdiff
path: root/includes/pages/admin_rooms.php
diff options
context:
space:
mode:
Diffstat (limited to 'includes/pages/admin_rooms.php')
-rw-r--r--includes/pages/admin_rooms.php9
1 files changed, 8 insertions, 1 deletions
diff --git a/includes/pages/admin_rooms.php b/includes/pages/admin_rooms.php
index bc0eb651..c55eb227 100644
--- a/includes/pages/admin_rooms.php
+++ b/includes/pages/admin_rooms.php
@@ -179,9 +179,16 @@ function admin_rooms()
]);
} elseif ($request->input('show') == 'delete') {
if ($request->hasPostData('ack')) {
+ $shifts = Shifts_by_room($room_id);
+ foreach ($shifts as $shift) {
+ $shift = Shift($shift['SID']);
+
+ UserWorkLog_from_shift($shift);
+ mail_shift_delete($shift);
+ }
+
Room_delete($room_id);
- engelsystem_log('Room deleted: ' . $name);
success(sprintf(__('Room %s deleted.'), $name));
redirect(page_link_to('admin_rooms'));
}