From 791ce45f43098ac47533e2d2ef8bcde76b6f64c7 Mon Sep 17 00:00:00 2001 From: Tuneer Roy <53184517+tuneerroy@users.noreply.github.com> Date: Thu, 9 Nov 2023 17:31:29 -0500 Subject: [PATCH 1/3] fix: ok this'll def work --- backend/laundry/views.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/backend/laundry/views.py b/backend/laundry/views.py index d8580016..299b636a 100644 --- a/backend/laundry/views.py +++ b/backend/laundry/views.py @@ -87,7 +87,7 @@ def compute_usage(hall_id): return Response({"error": "Invalid hall id passed to server."}, status=404) # [0]: available washers, [1]: available dryers, [2]: total number of LaundrySnapshots - data = [(0, 0, 0)] * 27 + data = [(0, 0, 0)] * 28 # used calculate the start and end dates min_date = timezone.localtime() From 9a255dee9a15fb04219e7315570f638131720fe9 Mon Sep 17 00:00:00 2001 From: Tuneer Roy <53184517+tuneerroy@users.noreply.github.com> Date: Thu, 9 Nov 2023 17:31:55 -0500 Subject: [PATCH 2/3] temp --- backend/laundry/views.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/backend/laundry/views.py b/backend/laundry/views.py index 299b636a..f5a80fec 100644 --- a/backend/laundry/views.py +++ b/backend/laundry/views.py @@ -82,7 +82,7 @@ def get_snapshot_info(hall_id): def compute_usage(hall_id): try: - (room, snapshots) = HallUsage.get_snapshot_info(hall_id) + (room, snapshots) = HallUsage.get_snapshot_info(hall_id except ValueError: return Response({"error": "Invalid hall id passed to server."}, status=404) From 4efa9e6dedc1e6b39e8e976db2895a90a86c4df5 Mon Sep 17 00:00:00 2001 From: Tuneer Roy <53184517+tuneerroy@users.noreply.github.com> Date: Thu, 9 Nov 2023 17:32:01 -0500 Subject: [PATCH 3/3] revert --- backend/laundry/views.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/backend/laundry/views.py b/backend/laundry/views.py index f5a80fec..299b636a 100644 --- a/backend/laundry/views.py +++ b/backend/laundry/views.py @@ -82,7 +82,7 @@ def get_snapshot_info(hall_id): def compute_usage(hall_id): try: - (room, snapshots) = HallUsage.get_snapshot_info(hall_id + (room, snapshots) = HallUsage.get_snapshot_info(hall_id) except ValueError: return Response({"error": "Invalid hall id passed to server."}, status=404)