2014-11-25 10:47:18 +01:00
.row
.col-md-12
.page-header
%h1
-if @track.new_record?
New
= @track.name
Track
.row
.col-md-12
2017-07-12 15:56:07 +03:00
= semantic_form_for(@track, url: (@track.new_record? ? admin_conference_program_tracks_path(@conference.short_title) : admin_conference_program_track_path(@conference.short_title, @track))) do |f|
2014-11-25 10:47:18 +01:00
= f.input :name
2017-06-29 23:39:56 +03:00
= f.input :short_name, hint: "A short and unique handle for the track, using only letters, numbers, underscores, and dashes. This will be used to identify the track in URLs etc. Example: 'my_awesome_track'", input_html: { required: 'required', pattern: '[a-zA-Z0-9_-]+', title: 'Only letters, numbers, underscores, and dashes.' }
2017-03-11 13:25:39 +05:30
= f.input :color, input_html: {size: 6, type: 'color'}, required: true
2017-07-12 15:56:07 +03:00
= f.input :start_date, as: :string, input_html: { id: 'registration-period-start-datepicker', start_date: @conference.start_date, end_date: @conference.end_date, readonly: 'readonly', required: @track.self_organized_and_accepted_or_confirmed? }
= f.input :end_date, as: :string, input_html: { id: 'registration-period-end-datepicker', readonly: 'readonly', required: @track.self_organized_and_accepted_or_confirmed? }
2017-08-08 12:41:37 +03:00
- if @conference.venue.try(:rooms)
2017-07-12 15:56:07 +03:00
= f.input :room, as: :select, collection: (@conference.venue.rooms).map {|room| ["#{room.name}", room.id]}, include_blank: true, label: 'Room', input_html: { class: 'select-help-toggle', required: @track.self_organized_and_accepted_or_confirmed? }
- else
2017-08-08 12:41:37 +03:00
%b
Please add a
= link_to 'venue', admin_conference_venue_path(@conference.short_title)
with
= link_to 'rooms', admin_conference_venue_rooms_path(@conference.short_title)
, if you want to select a room for the track.
2017-03-11 13:25:39 +05:30
= f.input :description, input_html: {rows: 2, data: { provide: 'markdown-editable' } }, hint: markdown_hint
2017-07-14 15:57:34 +03:00
= f.input :cfp_active, label: 'Allow event submitters to select this track for their proposal'
2017-03-11 13:25:39 +05:30
= f.action :submit, as: :button, button_html: { class: 'btn btn-primary' }