-
Notifications
You must be signed in to change notification settings - Fork 20
/
index.html.haml
50 lines (47 loc) · 2.26 KB
/
index.html.haml
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
- title t('actions.reviewer_sessions', count: @sessions.total_entries)
- show_actions!
= semantic_form_for @session_filter, url: reviewer_sessions_path(@conference), method: :get do |f|
= f.inputs do
= f.input :track_id, as: :select, collection: @tracks.map{|tr| [t(tr.title), tr.id]}, input_html: {tabindex: autotab}, include_blank: t("generic.all")
= f.input :session_type_id, as: :select, collection: @session_types.map{|st| [t(st.title), st.id]}, input_html: {tabindex: autotab}, include_blank: t("generic.all")
= f.input :audience_level_id, as: :select, collection: @audience_levels.map{|al| [t(al.title), al.id]}, input_html: {tabindex: autotab}, include_blank: t("generic.all")
= f.actions do
= f.action :submit, label: :filter_session, button_html: {tabindex: autotab}
%table.sessions
%thead
%tr
%th.session_id ID
%th.title= t('formtastic.labels.session.title')
%th.track= t('formtastic.labels.session.track_id')
%th.type= t('formtastic.labels.session.session_type_id')
%th.audience_level= t('formtastic.labels.session.audience_level_id')
- if @conference.has_early_review?
%th.reviews= t('review.early_review')
- if @conference.in_final_review_phase?
%th.reviews= t('review.final_review')
%th.action
%tbody
- @sessions.each do |session|
= content_tag_for(:tr, session, class: cycle(:odd, :even)) do
%td.session_id= session.id
%td.title
= link_to session.try(:title), session_path(@conference, session)
- if session.comments.size > 0
.commentCount= session.comments.size
%td.track
= t(session.track.title)
%td.type
= t(session.session_type.title)
%td.audience_level
= t(session.audience_level.title)
- if @conference.has_early_review?
%td.reviews
= session.early_reviews_count
- if @conference.in_final_review_phase?
%td.reviews
= session.final_reviews_count
%td.action
- if can?(:create, EarlyReview, session) || can?(:create, FinalReview, session)
= link_to t('actions.review_session'), new_session_review_path(@conference, session)
- if @sessions.total_pages > 1
#pagination= will_paginate(@sessions)