mirror of
https://github.com/LaCasemate/fab-manager.git
synced 2025-01-29 18:52:22 +01:00
{bug] unable to create events or trainings that are not multiples of SLOT_DURATION
This commit is contained in:
parent
570672c5db
commit
3624bee057
@ -3,6 +3,7 @@
|
|||||||
- Interface to manage partners
|
- Interface to manage partners
|
||||||
- Ability to define, per availability, a custom duration for the reservation slots
|
- Ability to define, per availability, a custom duration for the reservation slots
|
||||||
- Fix a bug: unable to change group if the previous was deactivated
|
- Fix a bug: unable to change group if the previous was deactivated
|
||||||
|
- Fix a bug: unable to create events or trainings that are not multiples of SLOT_DURATION
|
||||||
|
|
||||||
## v4.3.4 2020 April 14
|
## v4.3.4 2020 April 14
|
||||||
|
|
||||||
|
@ -160,6 +160,8 @@ class Availability < ApplicationRecord
|
|||||||
private
|
private
|
||||||
|
|
||||||
def length_must_be_slot_multiple
|
def length_must_be_slot_multiple
|
||||||
|
return unless available_type == 'machines' || available_type == 'space'
|
||||||
|
|
||||||
duration = slot_duration || ApplicationHelper::SLOT_DURATION
|
duration = slot_duration || ApplicationHelper::SLOT_DURATION
|
||||||
return unless end_at < (start_at + duration.minutes)
|
return unless end_at < (start_at + duration.minutes)
|
||||||
|
|
||||||
|
Loading…
x
Reference in New Issue
Block a user