mirror of
https://github.com/LaCasemate/fab-manager.git
synced 2025-03-15 12:29:16 +01:00
Allow last minute reservations by admins
This commit is contained in:
parent
3a2f488c56
commit
9b2e1909d9
@ -64,7 +64,7 @@ class CartItem::Reservation < CartItem::BaseItem
|
||||
return false
|
||||
end
|
||||
|
||||
if slot_db.start_at < reservation_deadline
|
||||
if slot_db.start_at < reservation_deadline && !@operator.privileged?
|
||||
@errors[:slot] = 'cannot reserve a slot ' + reservation_deadline_minutes.to_s + ' minutes prior to its start'
|
||||
return false
|
||||
end
|
||||
|
Loading…
x
Reference in New Issue
Block a user