osem-fcy/app/views/conference_registration/register.html.haml

46 lines
2.7 KiB
Text
Raw Normal View History

2013-01-07 09:04:09 +01:00
.container-fluid
.row-fluid
.span12
%h3.pull-left
Registration for
= @conference.title
2013-01-08 08:36:21 +01:00
- if @person.proposal_count(@conference) > 0
.row-fluid
.span12
%i
Please note: Registration is not automatically performed for speakers. If you're scheduled to speak at the conference, you still need to register!
2013-01-07 09:04:09 +01:00
.row-fluid
.span12
= semantic_form_for(@registration, :url => register_conference_path(@conference.short_title), :html => { :method => :put }) do |f|
= f.fields_for :person do
= f.inputs :public_name, :for => :person
= f.input :attending_social_events, :label => false
= f.input :attending_social_events_with_partner, :label => false
= f.input :using_affiliated_lodging, :label => false
= f.input :handicapped_access_required, :label => false
= f.input :arrival, :as => :string, :input_html => {:value => (f.object.arrival.to_formatted_s(:db_without_seconds) unless f.object.arrival.nil?), :id => "conference-reg-start-datepicker", :readonly => "readonly" }
= f.input :departure, :as => :string, :input_html => {:value => (f.object.departure.to_formatted_s(:db_without_seconds) unless f.object.arrival.nil?), :id => "conference-reg-end-datepicker", :readonly => "readonly" }
- if @conference.use_dietary_choices?
= f.input :dietary_choice, :collection => [["None", nil]] + @conference.dietary_choices.map {|x| [x.title, x.id]},
:include_blank => false, :label => "Special Dietary Restriction"
= f.input :other_dietary_choice, :input_html => {:rows => "2"}, :label => "Other Dietary Restictions (please describe)"
- if @conference.use_supporter_levels?
= f.semantic_fields_for :supporter_registration do |reg|
= reg.input :supporter_level, :as => :select, :collection => @conference.supporter_levels
= reg.input :code, :label => "Confirmation or registration code (if applicable)"
%span#supporter-link.help-block
2013-01-07 09:04:09 +01:00
- if @registered
= f.action :submit, :button_html => { :value => "Update Registration", :class => "btn btn-primary" }
= link_to "Unregister", register_conference_path(@conference.short_title),:method => :delete, :class => "btn btn-danger",
:confirm => "Are you sure you want to unregister?"
- else
= f.action :submit, :button_html => { :value => "Register", :class => "btn btn-primary" }
:javascript
$("#registration_supporter_registration_attributes_supporter_level_id").change(function () {
var str = "";
#{generate_supporter_level_js @conference}
$("#supporter-link").html(str);
})
.trigger('change');