mirror of
https://github.com/openSUSE/osem.git
synced 2026-08-13 19:54:02 +00:00
Allow track submitter to request specific dates Redirect to Tracks#edit if a track doesn't have a room or start/end date before accepting it Don't allow the submitter or the track organizers to edit the request after it has been accepted or confirmed Restrict track selection in proposals and move track selection from Proposals form to events helper Mark cfp_active of the tracks table as not null and fill in true if nil
66 lines
2.7 KiB
Text
66 lines
2.7 KiB
Text
.container
|
|
.row
|
|
.col-md-12.page-header
|
|
%h1
|
|
Track requests for
|
|
%span.notranslate
|
|
= @conference.title
|
|
|
|
- if @tracks.any?
|
|
.row
|
|
.col-md-12
|
|
%table.table.table-hover#tracks
|
|
%thead
|
|
%th Name
|
|
%th Short name
|
|
%th Description
|
|
%th Color
|
|
%th State
|
|
%th Start Date
|
|
%th End Date
|
|
%th Actions
|
|
%tbody
|
|
- @tracks.each do |track|
|
|
%tr
|
|
%td
|
|
= link_to(conference_program_track_path(@conference.short_title, track)) do
|
|
= track.name
|
|
%td
|
|
= track.short_name
|
|
%td
|
|
%p
|
|
= truncate(track.description)
|
|
%td
|
|
%span.label{style: "background-color: #{track.color}; color: #{ contrast_color(track.color) }"}
|
|
= track.color
|
|
%td
|
|
= track.state.humanize
|
|
%td
|
|
- if track.start_date
|
|
= track.start_date.strftime('%A, %B %-d. %Y')
|
|
- else
|
|
N/A
|
|
%td
|
|
- if track.end_date
|
|
= track.end_date.strftime('%A, %B %-d. %Y')
|
|
- else
|
|
N/A
|
|
%td
|
|
- if track.transition_possible? :confirm
|
|
= link_to 'Confirm', confirm_conference_program_track_path(@conference.short_title, track),
|
|
method: :patch, class: 'btn btn-mini btn-success', id: "confirm_track_#{track.id}"
|
|
- if track.transition_possible? :withdraw
|
|
= link_to 'Withdraw', withdraw_conference_program_track_path(@conference.short_title, track),
|
|
method: :patch, data: { confirm: 'Are you sure you want to withdraw this track request?' },
|
|
class: 'btn btn-mini btn-warning', id: "withdraw_track_request_#{track.id}"
|
|
- if track.transition_possible? :restart
|
|
= link_to 'Re-Submit', restart_conference_program_track_path(@conference.short_title, track),
|
|
method: :patch, class: 'btn btn-mini btn-success', id: "resubmit_track_request_#{track.id}"
|
|
- if can? :edit, track
|
|
= link_to 'Edit', edit_conference_program_track_path(@conference.short_title, track),
|
|
method: :get, class: 'btn btn-primary'
|
|
|
|
.row
|
|
.col-md-12
|
|
- if can? :new, @program.tracks.new
|
|
= link_to "New Track request", new_conference_program_track_path(@conference.short_title), class: 'btn btn-success pull-right'
|