Skip to content

Commit 738744c

Browse files
committed
machines under maintenance no longer show up when looking for machines
1 parent 6970ee5 commit 738744c

File tree

1 file changed

+1
-1
lines changed

1 file changed

+1
-1
lines changed

src/make_queue/views/reservation.py

Lines changed: 1 addition & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -379,7 +379,7 @@ def form_valid(self, form):
379379

380380
periods = []
381381
for machine in form.cleaned_data['machine_type'].machines.all():
382-
if not machine.get_status() == Machine.Status.OUT_OF_ORDER:
382+
if not (machine.get_status() == Machine.Status.OUT_OF_ORDER or machine.get_status() == Machine.Status.MAINTENANCE):
383383
periods.extend(self.get_periods(machine, required_time))
384384

385385
# Periods in the near future is more interesting than in the distant

0 commit comments

Comments
 (0)