Event model improvements

- Drop selected_event_schedule function
- Rename scheduled_room and scheduled_start_time to room and time as if there is no selected_schedule, the event is not scheduled.
This commit is contained in:
Ana 2016-08-01 21:25:12 +02:00
parent 5001848af7
commit a578167cf5
13 changed files with 32 additions and 35 deletions

View file

@ -49,7 +49,7 @@
= f.inputs 'Enable pre-registration' do
= f.input :require_registration, label: 'Require participants to register to your event'
- message = @event.scheduled_room ? "Value must be between 1 and #{@event.scheduled_room.size}" : 'Check room capacity after scheduling.'
- message = @event.room ? "Value must be between 1 and #{@event.room.size}" : 'Check room capacity after scheduling.'
= f.input :max_attendees, hint: 'The maximum number of participants. ' + message
- if current_user.has_any_role? :admin, { name: :organizer, resource: @conference }, { name: :cfp, resource: @conference }