diff --git a/app/assets/stylesheets/_application.scss b/app/assets/stylesheets/_application.scss
index 521dc96..6841219 100644
--- a/app/assets/stylesheets/_application.scss
+++ b/app/assets/stylesheets/_application.scss
@@ -1841,3 +1841,19 @@ html[data-lingua-franca-example="html"] {
@include translation-pointer;
}
+
+.workshop-list {
+ list-style: none;
+
+ .workshop-description {
+ font-size: 0.75em;
+ }
+
+ li {
+ border-bottom: 1px dashed #CCC;
+
+ &:last-child {
+ border-bottom: 0;
+ }
+ }
+}
\ No newline at end of file
diff --git a/app/controllers/conferences_controller.rb b/app/controllers/conferences_controller.rb
index 73aabc6..bf84a25 100644
--- a/app/controllers/conferences_controller.rb
+++ b/app/controllers/conferences_controller.rb
@@ -487,7 +487,9 @@ class ConferencesController < ApplicationController
@register_template = :questions if is_post
when :save
if is_post
- @registration ||= ConferenceRegistration.new
+ if (new_registration = (!@registration))
+ @registration = ConferenceRegistration.new
+ end
@registration.conference_id = @this_conference.id
@registration.user_id = current_user.id
@@ -508,6 +510,10 @@ class ConferencesController < ApplicationController
current_user.lastname = nil
current_user.save
+ if new_registration
+ UserMailer.registration_confirmation(@registration).deliver_now
+ end
+
@register_template = @registration.registration_fees_paid ? :done : :payment
end
when :payment
diff --git a/app/mailers/user_mailer.rb b/app/mailers/user_mailer.rb
index c028d11..bc9cd2c 100644
--- a/app/mailers/user_mailer.rb
+++ b/app/mailers/user_mailer.rb
@@ -64,13 +64,23 @@ class UserMailer < ActionMailer::Base
end
def email_confirmation(confirmation)
- #puts " == #{instance_methods.to_json.to_s} == "
@confirmation = confirmation
@host = UserMailer.default_url_options[:host]
mail to: confirmation.user.email,
subject: (_'email.subject.confirm_email','Please confirm your email address')
end
+ def registration_confirmation(registration)
+ @host = UserMailer.default_url_options[:host]
+ @registration = registration
+ @conference = Conference.find(@registration.conference_id)
+ @user = User.find(@registration.user_id)
+ mail to: @user.email,
+ subject: _('email.subject.registration_confirmed',
+ "Thank you for registering for #{@conference.title}",
+ :vars => {:conference_title => @conference.title})
+ end
+
def broadcast(host, subject, content, user, conference)
#puts " == #{instance_methods.to_json.to_s} == "
@host = host
diff --git a/app/models/conference.rb b/app/models/conference.rb
index 363c162..4630208 100644
--- a/app/models/conference.rb
+++ b/app/models/conference.rb
@@ -35,5 +35,8 @@ class Conference < ActiveRecord::Base
action = action.to_sym
'/conferences/' + conference_type.slug + '/' + slug + (action == :show ? '' : '/' + action.to_s)
end
+ def location
+ organizations.first.location
+ end
end
diff --git a/app/views/application/home.html.haml b/app/views/application/home.html.haml
index af6b8ed..f03c76e 100644
--- a/app/views/application/home.html.haml
+++ b/app/views/application/home.html.haml
@@ -4,7 +4,10 @@
%article
%h2=_!@conference.title
=@conference.info.html_safe
-
-- # %article.supplementary
-- # %h2=_'section_titles.bikebike.About_BikeBike'
-- # %p=_'section_content.bikebike.about_bikebike', :p
+ %h3=_'acticles.conferences.headings.Proposed_Workshops'
+ %p=_'acticles.conferences.paragraphs.Proposed_Workshops', "Would you like to facilitate your own workshop? Simply register and visit the workshops page. If you have already registered you can access the page by restarting the registration process."
+ %ul.workshop-list
+ - @conference.workshops.each do |w|
+ %li
+ %h4=w.title
+ .workshop-description=markdown w.info
diff --git a/app/views/user_mailer/registration_confirmation.html.haml b/app/views/user_mailer/registration_confirmation.html.haml
new file mode 100644
index 0000000..0172be4
--- /dev/null
+++ b/app/views/user_mailer/registration_confirmation.html.haml
@@ -0,0 +1,4 @@
+%p=_'email.general.paragraph.thank_you', "Thank you #{@user.firstname},", :vars => {:name => @user.firstname}
+%p=_'email.registration.paragraph.confirmed', "You have successfully registered for #{@conference.title}. You can modify your registration details, pay, or add workshops at any time by restarting the registration process. If you have yet to pay or add your workshops and plan to do so, we ask that you take care of it as soon as possible to help us prepare in advance of your arrival.", :vars => {:conference_title => @conference.title}
+
+%p=_'email.general.paragraph.see_you', "See you in #{@conference.location.city}!", :vars => {:conference_location => @conference.location.city}
\ No newline at end of file
diff --git a/app/views/user_mailer/registration_confirmation.text.haml b/app/views/user_mailer/registration_confirmation.text.haml
new file mode 100644
index 0000000..e5dd795
--- /dev/null
+++ b/app/views/user_mailer/registration_confirmation.text.haml
@@ -0,0 +1,5 @@
+=_'email.general.paragraph.thank_you', "Thank you #{@user.firstname},", :vars => {:name => @user.firstname}
+
+=_'email.registration.paragraph.confirmed', "You have successfully registered for #{@conference.title}. You can modify your registration details, pay, or add workshops at any time by restarting the registration process. If you have yet to pay or add your workshops and plan to do so, we ask that you take care of it as soon as possible to help us prepare in advance of your arrival.", :vars => {:conference_title => @conference.title}
+
+=_'email.general.paragraph.see_you', "See you in #{@conference.location.city}!", :vars => {:conference_location => @conference.location.city}
\ No newline at end of file
diff --git a/config/locales/data/html_records/Broadcast-message---1.html b/config/locales/data/html_records/Broadcast-message---1.html
index ff1f60d..bb8edac 100644
--- a/config/locales/data/html_records/Broadcast-message---1.html
+++ b/config/locales/data/html_records/Broadcast-message---1.html
@@ -46,7 +46,7 @@
San Marcos, Texas
-August 10 – 14, 2015
+August 12 – 16, 2015
@@ -60,6 +60,10 @@ August 10 – 14, 2015
My Bike!Bike!
Curabitur non nulla sit amet nisl tempus convallis quis ac lectus.
+
Proposed Workshops
+
Would you like to facilitate your own workshop? Simply register and visit the workshops page. If you have already registered you can access the page by restarting the registration process.
Curabitur non nulla sit amet nisl tempus convallis quis ac lectus.
+
Proposed Workshops
+
Would you like to facilitate your own workshop? Simply register and visit the workshops page. If you have already registered you can access the page by restarting the registration process.
Curabitur non nulla sit amet nisl tempus convallis quis ac lectus.
+
Proposed Workshops
+
Would you like to facilitate your own workshop? Simply register and visit the workshops page. If you have already registered you can access the page by restarting the registration process.
+Curabitur non nulla sit amet nisl tempus convallis quis ac lectus.
+
Proposed Workshops
+
Would you like to facilitate your own workshop? Simply register and visit the workshops page. If you have already registered you can access the page by restarting the registration process.
+
+
@@ -94,7 +92,7 @@ EN
-
+
EN
English
diff --git a/config/locales/data/html_records/Create-workshop--conferences.MyBikeBike.register.html b/config/locales/data/html_records/Create-workshop--conferences.MyBikeBike.register.html
index 8ac7ea1..5f4c59b 100644
--- a/config/locales/data/html_records/Create-workshop--conferences.MyBikeBike.register.html
+++ b/config/locales/data/html_records/Create-workshop--conferences.MyBikeBike.register.html
@@ -72,7 +72,7 @@
diff --git a/config/locales/data/html_records/See-a-more-info-link---1.html b/config/locales/data/html_records/See-a-more-info-link---1.html
index 7a767ab..774ad71 100644
--- a/config/locales/data/html_records/See-a-more-info-link---1.html
+++ b/config/locales/data/html_records/See-a-more-info-link---1.html
@@ -50,7 +50,7 @@
Halifax, Nova Scotia
-August 10 – 14, 2015
+August 12 – 16, 2015
@@ -64,6 +64,10 @@ August 10 – 14, 2015
My Bike!Bike!
Curabitur non nulla sit amet nisl tempus convallis quis ac lectus.
+
Proposed Workshops
+
Would you like to facilitate your own workshop? Simply register and visit the workshops page. If you have already registered you can access the page by restarting the registration process.
Curabitur non nulla sit amet nisl tempus convallis quis ac lectus.
+
Proposed Workshops
+
Would you like to facilitate your own workshop? Simply register and visit the workshops page. If you have already registered you can access the page by restarting the registration process.
Curabitur non nulla sit amet nisl tempus convallis quis ac lectus.
+
Proposed Workshops
+
Would you like to facilitate your own workshop? Simply register and visit the workshops page. If you have already registered you can access the page by restarting the registration process.
Curabitur non nulla sit amet nisl tempus convallis quis ac lectus.
+
Proposed Workshops
+
Would you like to facilitate your own workshop? Simply register and visit the workshops page. If you have already registered you can access the page by restarting the registration process.
Curabitur non nulla sit amet nisl tempus convallis quis ac lectus.
+
Proposed Workshops
+
Would you like to facilitate your own workshop? Simply register and visit the workshops page. If you have already registered you can access the page by restarting the registration process.
Curabitur non nulla sit amet nisl tempus convallis quis ac lectus.
+
Proposed Workshops
+
Would you like to facilitate your own workshop? Simply register and visit the workshops page. If you have already registered you can access the page by restarting the registration process.
+
+
diff --git a/config/locales/data/translation-info.yml b/config/locales/data/translation-info.yml
index ca87afa..c86da3c 100644
--- a/config/locales/data/translation-info.yml
+++ b/config/locales/data/translation-info.yml
@@ -77,6 +77,41 @@ date.date_span:
- Create-workshop---1
- Broadcast-message--
- Broadcast-message---1
+acticles.conferences.headings.Proposed_Workshops:
+ pages:
+ - "/"
+ examples:
+ - See-a-more-info-link--
+ - See-a-more-info-link---1
+ - See-a-register-link--
+ - See-a-register-link---1
+ - Start-registration-from-landing-page--
+ - Start-registration-from-landing-page---1
+ - View-stats--
+ - View-stats---1
+ - Create-workshop--
+ - Create-workshop---1
+ - Broadcast-message--
+ - Broadcast-message---1
+acticles.conferences.paragraphs.Proposed_Workshops:
+ pages:
+ - "/"
+ context: Would you like to facilitate your own workshop? Simply register and visit
+ the workshops page. If you have already registered you can access the page by
+ restarting the registration process.
+ examples:
+ - See-a-more-info-link--
+ - See-a-more-info-link---1
+ - See-a-register-link--
+ - See-a-register-link---1
+ - Start-registration-from-landing-page--
+ - Start-registration-from-landing-page---1
+ - View-stats--
+ - View-stats---1
+ - Create-workshop--
+ - Create-workshop---1
+ - Broadcast-message--
+ - Broadcast-message---1
page_descriptions.home:
pages:
- "/"
@@ -1152,6 +1187,45 @@ forms.labels.generic.other:
- "/conferences/:slug/register"
examples:
- Start-registration-from-landing-page--conferences.MyBikeBike.register-3
+email.subject.registration_confirmed:
+ pages:
+ - "/conferences/:slug/register"
+ context: Thank you for registering for My Bike!Bike!
+ vars:
+ - :conference_title
+ examples:
+ - Start-registration-from-landing-page--conferences.MyBikeBike.register-4
+email.general.paragraph.thank_you:
+ pages:
+ - "/conferences/:slug/register"
+ context: Thank you John Doe,
+ vars:
+ - :name
+ examples:
+ - Start-registration-from-landing-page--conferences.MyBikeBike.register-4
+ - Start-registration-from-landing-page--conferences.MyBikeBike.register-4
+email.registration.paragraph.confirmed:
+ pages:
+ - "/conferences/:slug/register"
+ context: You have successfully registered for My Bike!Bike!. You can modify your
+ registration details, pay, or add workshops at any time by restarting the registration
+ process. If you have yet to pay or add your workshops and plan to do so, we ask
+ that you take care of it as soon as possible to help us prepare in advance of
+ your arrival.
+ vars:
+ - :conference_title
+ examples:
+ - Start-registration-from-landing-page--conferences.MyBikeBike.register-4
+ - Start-registration-from-landing-page--conferences.MyBikeBike.register-4
+email.general.paragraph.see_you:
+ pages:
+ - "/conferences/:slug/register"
+ context: See you in Halifax!
+ vars:
+ - :conference_location
+ examples:
+ - Start-registration-from-landing-page--conferences.MyBikeBike.register-4
+ - Start-registration-from-landing-page--conferences.MyBikeBike.register-4
articles.conference_registration.headings.Payment:
pages:
- "/conferences/:slug/register"