Volunteers, positions and days and volunteers list for admin, volunteering option for attendees
This commit is contained in:
parent
125d5fe3ff
commit
64b2b8b3f8
31 changed files with 335 additions and 79 deletions
|
|
@ -43,4 +43,7 @@
|
|||
%li.active= link_to "Dietary Choices", "#"
|
||||
- else
|
||||
%li= link_to "Dietary Choices", admin_conference_dietary_list_path(@conference.short_title)
|
||||
|
||||
- if activated == "volunteers"
|
||||
%li.active= link_to "Volunteer Options", "#"
|
||||
- else
|
||||
%li= link_to "Volunteer Options", admin_conference_volunteer_options_path(@conference.short_title)
|
||||
7
app/views/admin/volunteers/_vday_fields.html.erb
Normal file
7
app/views/admin/volunteers/_vday_fields.html.erb
Normal file
|
|
@ -0,0 +1,7 @@
|
|||
<div class="nested-fields">
|
||||
<%= f.inputs do %>
|
||||
<%= f.date_select :day %>
|
||||
<%= f.input :description, :input_html => {:rows => "2", :class => "span8"} %>
|
||||
<%= remove_association_link :vday, f %>
|
||||
<% end %>
|
||||
</div>
|
||||
19
app/views/admin/volunteers/_volunteers_table.html.haml
Normal file
19
app/views/admin/volunteers/_volunteers_table.html.haml
Normal file
|
|
@ -0,0 +1,19 @@
|
|||
%table.table.table-striped.table-bordered.table-hover#speakertable
|
||||
%thead
|
||||
%th First Name
|
||||
%th Last Name
|
||||
%th Email
|
||||
%th Mobile
|
||||
%th Languages
|
||||
%th Experience
|
||||
%th Tshirt Size
|
||||
%tbody
|
||||
- @volunteers.each do |volunteer|
|
||||
%tr
|
||||
%td= volunteer.first_name
|
||||
%td= volunteer.last_name
|
||||
%td= volunteer.email
|
||||
%td= volunteer.mobile
|
||||
%td= volunteer.languages
|
||||
%td= volunteer.volunteer_experience
|
||||
%td= volunteer.tshirt
|
||||
8
app/views/admin/volunteers/_vposition_fields.html.erb
Normal file
8
app/views/admin/volunteers/_vposition_fields.html.erb
Normal file
|
|
@ -0,0 +1,8 @@
|
|||
<div class="nested-fields">
|
||||
<%= f.inputs do %>
|
||||
<%= f.input :title %>
|
||||
<%= f.input :description, :input_html => {:rows => "2", :class => "span8"}%>
|
||||
<%= f.input :vdays, :collection => @conference.vdays.map {|x| [x.day, x.id]}, :label => "Position is required for the following days:"%>
|
||||
<%= remove_association_link :vposition, f %>
|
||||
<% end %>
|
||||
</div>
|
||||
15
app/views/admin/volunteers/index.html.haml
Normal file
15
app/views/admin/volunteers/index.html.haml
Normal file
|
|
@ -0,0 +1,15 @@
|
|||
.container-fluid
|
||||
.row-fluid
|
||||
.span3
|
||||
= render 'admin/conference/sidebar', :activated => "Volunteers"
|
||||
.span9
|
||||
= semantic_form_for(@conference, :url => admin_conference_volunteer_options_update_path(@conference.short_title)) do |f|
|
||||
= f.action :submit, :as => :button, :button_html => {:class => "btn btn-primary"}
|
||||
%br
|
||||
%br
|
||||
.span5
|
||||
= f.input :use_vdays, :label => false
|
||||
= dynamic_association :vdays, "Volunteer Days", f
|
||||
.span5
|
||||
= f.input :use_vpositions, :label => false
|
||||
= dynamic_association :vpositions, "Volunteer positions", f
|
||||
6
app/views/admin/volunteers/show.html.haml
Normal file
6
app/views/admin/volunteers/show.html.haml
Normal file
|
|
@ -0,0 +1,6 @@
|
|||
- if @volunteers.count > 0
|
||||
%h3= "Volunteers (#{@volunteers.count})"
|
||||
%br
|
||||
= render :partial => "volunteers_table"
|
||||
- else
|
||||
%h3 There are no volunteers yet!
|
||||
Loading…
Add table
Add a link
Reference in a new issue