From e57d5b019f87a39417973dccfc25cfa45d2abcea Mon Sep 17 00:00:00 2001 From: ppound Date: Fri, 30 Oct 2020 13:46:31 -0300 Subject: [PATCH] added logic so Button shows up correctly on weekends and changed weekday mornings to 830 timeslot --- view/room_reservations_calendar.view.inc | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/view/room_reservations_calendar.view.inc b/view/room_reservations_calendar.view.inc index a922663..cb98cf1 100644 --- a/view/room_reservations_calendar.view.inc +++ b/view/room_reservations_calendar.view.inc @@ -228,7 +228,7 @@ function theme_room_reservations($variables) { $viewable_class = ''; $widthclass = ''; // BEGIN UPEI CHANGES - if ($booked_class == 'reservable' && ($time_slot['time'] == '0900' || $time_slot['time'] == '1330' || $time_slot['time'] == '1230') && + if ($booked_class == 'reservable' && (($day_of_week != 'Saturday' && $day_of_week!= 'Sunday' && ($time_slot['time'] == '0830' || $time_slot['time'] == '1330')) || (($day_of_week == 'Saturday' || $day_of_week == 'Sunday') && $time_slot['time'] == '1230')) && (user_access('create room reservations standard') || user_access('create room reservations extended') || user_access('administer room reservations system'))) { $link = l( '', @@ -238,7 +238,7 @@ function theme_room_reservations($variables) { $viewable = ''; } // The time slot can be reserved by the current user, but the user must login first. - elseif ($booked_class == 'open' && ($time_slot['time'] == '0900' || $time_slot['time'] == '1330' || $time_slot['time'] == '1230')) { + elseif ($booked_class == 'open' && (($day_of_week != 'Saturday' && $day_of_week!= 'Sunday' && ($time_slot['time'] == '0830' || $time_slot['time'] == '1330')) || (($day_of_week == 'Saturday' || $day_of_week == 'Sunday') && $time_slot['time'] == '1230'))) { $link = "";