Fixed registration for BBSE2017
This commit is contained in:
parent
cb016915e4
commit
99be23056e
@ -2977,11 +2977,15 @@ a.logo {
|
||||
.conference-details {
|
||||
.links {
|
||||
text-align: center;
|
||||
font-size: 1.25em;
|
||||
margin-bottom: 2em;
|
||||
|
||||
.button {
|
||||
margin: 0 0.25em 0.5em;
|
||||
vertical-align: middle;
|
||||
}
|
||||
|
||||
.register {
|
||||
font-size: 1.5em;
|
||||
}
|
||||
}
|
||||
}
|
||||
@ -3881,6 +3885,7 @@ body.policy .policy-agreement ul {
|
||||
|
||||
> div {
|
||||
vertical-align: top;
|
||||
margin-top: 2em;
|
||||
|
||||
h3, p:first-child {
|
||||
margin-top: 0;
|
||||
|
@ -32,7 +32,7 @@ class ConferencesController < ApplicationController
|
||||
|
||||
if @this_conference.host? current_user
|
||||
@links ||= []
|
||||
@links = [:administrate]
|
||||
@links = [:administrate, :register]
|
||||
end
|
||||
end
|
||||
end
|
||||
@ -233,14 +233,14 @@ class ConferencesController < ApplicationController
|
||||
steps ||= registration_steps
|
||||
|
||||
# make sure we're on a valid step
|
||||
@register_template ||= (params[:step] || current_step).to_sym
|
||||
@register_template ||= (params[:step] || view_context.current_step).to_sym
|
||||
|
||||
if logged_in? && @register_template != :paypal_confirm
|
||||
# if we're logged in
|
||||
if !steps.include?(@register_template)
|
||||
# and we are not viewing a valid step
|
||||
return redirect_to register_path(@this_conference.slug)
|
||||
elsif @register_template != current_step && !registration_complete? && !@registration.steps_completed.include?(@register_template.to_s)
|
||||
elsif @register_template != view_context.current_step && !registration_complete? && !@registration.steps_completed.include?(@register_template.to_s)
|
||||
# or the step hasn't been reached, registration is not yet complete, and we're not viewing the latest incomplete step
|
||||
return redirect_to register_path(@this_conference.slug)
|
||||
end
|
||||
|
@ -238,8 +238,8 @@ module ApplicationHelper
|
||||
|
||||
def registration_steps(conference = @conference)
|
||||
{
|
||||
pre: [:policy, :basic_info, :workshops],
|
||||
open: [:policy, :basic_info, :questions, :payment, :workshops]
|
||||
pre: [:policy, :contact_info, :workshops],
|
||||
open: [:policy, :contact_info, :questions, :payment, :workshops]
|
||||
}[@this_conference.registration_status]
|
||||
end
|
||||
|
||||
|
@ -1,14 +1,14 @@
|
||||
= columns(medium: 12) do
|
||||
%p=_'articles.conference_registration.paragraphs.Registration_Info', :p, vars: { city: @this_conference.location.city }
|
||||
%p=_'articles.conference_registration.paragraphs.Registration_Info', :p, vars: { city: @this_conference.city_name }
|
||||
= form_tag register_path(@this_conference.slug), class: [:centered, :clearfix] do
|
||||
= columns(medium: 12) do
|
||||
= radiobuttons :housing, ConferenceRegistration.all_housing_options, @registration.housing, 'articles.conference_registration.questions.housing', heading: 'articles.conference_registration.headings.housing', vertical: true, big: true, inline: true
|
||||
= fieldset :hosting_dates, heading: 'articles.conference_registration.headings.arrival_and_departure', vars: { city: @this_conference.location.city } do
|
||||
= selectfield :arrival, @registration.arrival || @this_conference.start_date, conference_days_options_list(:before_plus_one)
|
||||
= selectfield :departure, @registration.departure || @this_conference.start_date, conference_days_options_list(:after_minus_one)
|
||||
= radiobuttons :bike, ConferenceRegistration.all_bike_options, @registration.bike, 'articles.conference_registration.questions.bike', heading: 'articles.conference_registration.headings.bike', inline: true, big: true
|
||||
= radiobuttons :food, ConferenceRegistration.all_food_options, @registration.food, 'articles.conference_registration.questions.food', heading: 'articles.conference_registration.headings.food', inline: true, big: true
|
||||
= emailfield :companion, (@registration.housing_data['companions'] || [nil]).first, heading: 'articles.conference_registration.headings.companion', help: 'articles.conference_registration.paragraphs.companion', big: true
|
||||
= textfield :allergies, @registration.allergies, heading: 'articles.conference_registration.headings.allergies'
|
||||
= textarea :other, @registration.other, plain: true, heading: 'articles.conference_registration.headings.other'
|
||||
= button_tag :register, :value => :questions
|
||||
= columns(medium: 12) do
|
||||
= radiobuttons :housing, ConferenceRegistration.all_housing_options, @registration.housing, 'articles.conference_registration.questions.housing', heading: 'articles.conference_registration.headings.housing', vertical: true, big: true, inline: true
|
||||
= fieldset :hosting_dates, heading: 'articles.conference_registration.headings.arrival_and_departure', vars: { city: @this_conference.city_name } do
|
||||
= selectfield :arrival, @registration.arrival || @this_conference.start_date, conference_days_options_list(:before_plus_one)
|
||||
= selectfield :departure, @registration.departure || @this_conference.start_date, conference_days_options_list(:after_minus_one)
|
||||
= radiobuttons :bike, ConferenceRegistration.all_bike_options, @registration.bike, 'articles.conference_registration.questions.bike', heading: 'articles.conference_registration.headings.bike', inline: true, big: true
|
||||
= radiobuttons :food, ConferenceRegistration.all_food_options, @registration.food, 'articles.conference_registration.questions.food', heading: 'articles.conference_registration.headings.food', inline: true, big: true
|
||||
= emailfield :companion, (@registration.housing_data['companions'] || [nil]).first, heading: 'articles.conference_registration.headings.companion', help: 'articles.conference_registration.paragraphs.companion', big: true
|
||||
= textfield :allergies, @registration.allergies, heading: 'articles.conference_registration.headings.allergies'
|
||||
= textarea :other, @registration.other, plain: true, heading: 'articles.conference_registration.headings.other'
|
||||
= button_tag :register, :value => :questions
|
||||
|
@ -1,4 +1,4 @@
|
||||
= render :partial => 'conferences/page_header', :locals => {:page_key => 'Conference_Administration'}
|
||||
= render :partial => 'conferences/page_header', :locals => {:page_key => 'Conference_Registration'}
|
||||
- if @warnings.present?
|
||||
= row class: 'warnings', tag: :ul do
|
||||
- @warnings.each do | warning |
|
||||
|
@ -5,4 +5,4 @@
|
||||
- else
|
||||
%p=_'email.registration.paragraph.confirmed', :vars => {:conference_title => @conference.title}
|
||||
|
||||
%p=_'email.general.paragraph.see_you', :vars => {:conference_location => @conference.location.city}
|
||||
%p=_'email.general.paragraph.see_you', :vars => {:conference_location => @conference.city_name}
|
||||
|
@ -5,4 +5,4 @@
|
||||
- else
|
||||
=_'email.registration.paragraph.confirmed', :vars => {:conference_title => @conference.title}
|
||||
|
||||
=_'email.general.paragraph.see_you', :vars => {:conference_location => @conference.location.city}
|
||||
=_'email.general.paragraph.see_you', :vars => {:conference_location => @conference.city_name}
|
@ -1156,6 +1156,7 @@ en:
|
||||
Hosting: Hosting
|
||||
can_provide_housing: Can you provide housing to attendees visiting the city?
|
||||
questions: Your Visit
|
||||
basic_info: Your Visit
|
||||
host:
|
||||
considerations: Special Considerations
|
||||
space: Available Space
|
||||
|
@ -804,6 +804,7 @@ es:
|
||||
Workshops_You_Have_Requested: Talleres que te ofreciste a impartir
|
||||
All_Workshops: Todos los otros talleres
|
||||
questions: Tu Visita
|
||||
basic_info: Tu Visita
|
||||
companion: Acompañante
|
||||
host:
|
||||
considerations: Consideraciones especiales
|
||||
|
Loading…
x
Reference in New Issue
Block a user