Registration for Events
This commit is contained in:
parent
f188fd5575
commit
01ec43e53a
35 changed files with 522 additions and 46 deletions
25
app/views/admin/users/_event_registrations.html.haml
Normal file
25
app/views/admin/users/_event_registrations.html.haml
Normal file
|
|
@ -0,0 +1,25 @@
|
|||
.row
|
||||
.col-md-12.page-header
|
||||
%h2
|
||||
Registrations to Events
|
||||
|
||||
.col-md-12
|
||||
.well
|
||||
%table.table.table-bordered.table-striped.table-hover.datatable#event_registrations
|
||||
%thead
|
||||
%th ID
|
||||
%th Conference
|
||||
%th Title
|
||||
%th Attended
|
||||
%tbody
|
||||
- @user.events_registrations.each do |event_registration|
|
||||
- event = event_registration.event
|
||||
%tr
|
||||
%td= event.id
|
||||
%td= link_to event.program.conference.short_title, admin_conference_path(event.program.conference.short_title)
|
||||
%td= link_to event.title, admin_conference_program_event_path(event.program.conference.short_title, event)
|
||||
%td
|
||||
- if @user.attended_event?(event)
|
||||
%i.fa.fa-check.text-success
|
||||
- else
|
||||
%i.fa.fa-times.text-danger
|
||||
|
|
@ -7,6 +7,8 @@
|
|||
- unless @user.events.blank?
|
||||
%li{class: "#{'active' if params[:tab] == 'submissions-content'}"}
|
||||
= link_to 'Submissions', '#submissions-content', 'data-toggle'=>'tab'
|
||||
%li{class: "#{'active' if params[:tab] == 'event_registrations-content'}"}
|
||||
= link_to 'Event Registrations', '#event_registrations', 'data-toggle'=>'tab'
|
||||
.tab-content
|
||||
#user-info-content.tab-pane{class: "#{'active' unless params[:tab] == 'submissions-content'}"}
|
||||
- if can? :edit, @user
|
||||
|
|
@ -31,3 +33,5 @@
|
|||
%td= @user.send(attr)
|
||||
#submissions-content.tab-pane{class: "#{'active' if params[:tab] == 'submissions-content'}"}
|
||||
= render 'submissions'
|
||||
#event_registrations.tab-pane{class: "#{'active' if params[:tab] == 'event_registrations'}"}
|
||||
= render 'event_registrations'
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue