diff --git a/app/assets/javascripts/templates/registration_authentication.html.haml b/app/assets/javascripts/templates/registration_authentication.html.haml
index f277c50abc..b5a525c3f2 100644
--- a/app/assets/javascripts/templates/registration_authentication.html.haml
+++ b/app/assets/javascripts/templates/registration_authentication.html.haml
@@ -1,7 +1,7 @@
.container
.row.modal-centered
- %h2 {{'welcome_to_ofn' | t}}
- %h5 {{'signup_or_login' | t}}:
+ %h2 {{'js.registration.welcome_to_ofn' | t}}
+ %h5 {{'js.registration.signup_or_login' | t}}:
%div{"ng-controller" => "AuthenticationCtrl"}
%tabset
%ng-include{src: "'signup.html'"}
@@ -9,9 +9,9 @@
%ng-include{src: "'forgot.html'"}
%div{ ng: { show: "active('/signup')"} }
%hr
- {{'have_an_account' | t}}
+ {{'js.registration.have_an_account' | t}}
%a{ href: "", ng: { click: "select('/login')"}}
- {{'action_login' | t}}
+ {{'js.registration.action_login' | t}}
%a.close-reveal-modal{"ng-click" => "$close()"}
%i.ofn-i_009-close
diff --git a/app/views/registration/steps/_about.html.haml b/app/views/registration/steps/_about.html.haml
index 529fdebea3..5ec5dbb2c7 100644
--- a/app/views/registration/steps/_about.html.haml
+++ b/app/views/registration/steps/_about.html.haml
@@ -4,9 +4,9 @@
.row
.small-12.columns
%header
- %h2 {{'enterprise_about_headline' | t}}
+ %h2= t(".headline")
%h5
- {{'enterprise_about_message' | t}}
+ = t(".message")
%span{ ng: { class: "{brick: !enterprise.is_primary_producer, turquoise: enterprise.is_primary_producer}" } }
{{ enterprise.name }}
@@ -14,33 +14,33 @@
.row
.small-12.columns
.alert-box.info{ "ofn-inline-alert" => true, ng: { show: "visible" } }
- %h6{ "ng-bind" => "'enterprise_success' | t:{enterprise: enterprise.name}" }
- %span {{'enterprise_registration_exit_message' | t}}
+ %h6{ "ng-bind" => "'registration.steps.about.success' | t:{enterprise: enterprise.name}" }
+ %span= t(".registration_exit_message")
%a.close{ ng: { click: "close()" } } ×
.small-12.large-8.columns
.row
.small-12.columns
.field
- %label{ for: 'enterprise_description' } {{'enterprise_description' | t}}:
- %input.chunky{ id: 'enterprise_description', placeholder: "{{'enterprise_description_placeholder' | t}}", ng: { model: 'enterprise.description' } }
+ %label{ for: 'enterprise_description' }= t(".enterprise_description")
+ %input.chunky{ id: 'enterprise_description', placeholder: "{{'registration.steps.about.enterprise_description_placeholder' | t}}", ng: { model: 'enterprise.description' } }
.row
.small-12.columns
.field
- %label{ for: 'enterprise_long_desc' } {{'enterprise_long_desc' | t}}:
- %textarea.chunky{ id: 'enterprise_long_desc', rows: 6, placeholder: "{{'enterprise_long_desc_placeholder' | t}}", ng: { model: 'enterprise.long_description' } }
- %small{ "ng-bind" => "'enterprise_long_desc_length' | t:{num: enterprise.long_description.length}" }
+ %label{ for: 'enterprise_long_desc' }= t(".enterprise_long_desc")
+ %textarea.chunky{ id: 'enterprise_long_desc', rows: 6, placeholder: "{{'registration.steps.about.enterprise_long_desc_placeholder' | t}}", ng: { model: 'enterprise.long_description' } }
+ %small{ "ng-bind" => "'registration.steps.about.enterprise_long_desc_length' | t:{num: enterprise.long_description.length}" }
.small-12.large-4.columns
.row
.small-12.columns
.field
- %label{ for: 'enterprise_abn' } {{'enterprise_abn' | t}}:
- %input.chunky{ id: 'enterprise_abn', placeholder: "{{'enterprise_abn_placeholder' | t}}", ng: { model: 'enterprise.abn' } }
+ %label{ for: 'enterprise_abn' }= t(".enterprise_abn")+":"
+ %input.chunky{ id: 'enterprise_abn', placeholder: "{{'registration.steps.about.enterprise_abn_placeholder' | t}}", ng: { model: 'enterprise.abn' } }
.row
.small-12.columns
.field
- %label{ for: 'enterprise_acn' } {{'enterprise_acn' | t}}:
- %input.chunky{ id: 'enterprise_acn', placeholder: "{{'enterprise_acn_placeholder' | t}}", ng: { model: 'enterprise.acn' } }
+ %label{ for: 'enterprise_acn' }= t(".enterprise_acn")+":"
+ %input.chunky{ id: 'enterprise_acn', placeholder: "{{'registration.steps.about.enterprise_acn_placeholder' | t}}", ng: { model: 'enterprise.acn' } }
.row
.small-12.columns
.field
@@ -50,7 +50,7 @@
%input{ id: 'enterprise_charges_sales_tax_false', type: 'radio', name: 'charges_sales_tax', value: 'false', required: true, ng: { model: 'enterprise.charges_sales_tax' } }
%label{ for: 'enterprise_charges_sales_tax_false' } {{'say_no' | t}}
%span.error.small-12.columns{ ng: { show: "about.charges_sales_tax.$error.required && submitted" } }
- {{'enterprise_tax_required' | t}}
+ = t(".enterprise_tax_required")
.row.buttons.pad-top
.small-12.columns
diff --git a/app/views/registration/steps/_contact.html.haml b/app/views/registration/steps/_contact.html.haml
index 746503282d..eed9c25c73 100644
--- a/app/views/registration/steps/_contact.html.haml
+++ b/app/views/registration/steps/_contact.html.haml
@@ -4,26 +4,26 @@
.row
.small-12.columns
%header
- %h2 {{'registration_greeting' | t}}
- %h5{ "ng-bind" => "'who_is_managing_enterprise' | t:{enterprise: enterprise.name}" }
+ %h2= t('registration.steps.introduction.registration_greeting')
+ %h5{ "ng-bind" => "'registration.steps.contact.who_is_managing_enterprise' | t:{enterprise: enterprise.name}" }
%form{ name: 'contact', novalidate: true, ng: { controller: "RegistrationFormCtrl", submit: "selectIfValid('type',contact)" } }
.row.content
.small-12.medium-12.large-7.columns
.row
.small-12.columns.field
- %label{ for: 'enterprise_contact' } {{'enterprise.registration.modal.steps.contact.contact_field' | t}}:
- %input.chunky.small-12.columns{ id: 'enterprise_contact', name: 'contact_name', required: true, placeholder: "{{'enterprise.registration.modal.steps.contact.contact_field_placeholder' | t}}", ng: { model: 'enterprise.contact_name' } }
+ %label{ for: 'enterprise_contact' }= t(".contact_field")
+ %input.chunky.small-12.columns{ id: 'enterprise_contact', name: 'contact_name', required: true, placeholder: "{{'registration.steps.contact.contact_field_placeholder' | t}}", ng: { model: 'enterprise.contact_name' } }
%span.error.small-12.columns{ ng: { show: "contact.contact_name.$error.required && submitted" } }
- {{'enterprise.registration.modal.steps.contact.contact_field_required' | t}}
+ = t(".contact_field_required")
.row
.small-12.columns.field
- %label{ for: 'enterprise_email_address' } {{'admin.enterprises.form.contact.email_address' | t}}:
+ %label{ for: 'enterprise_email_address' }= t("admin.enterprises.form.contact.email_address")+":"
%input.chunky.small-12.columns{ id: 'enterprise_email_address', name: 'email_address', type: 'email', placeholder: t('admin.enterprises.form.contact.email_address_placeholder'), ng: { model: 'enterprise.email_address' } }
.row
.small-12.columns.field
- %label{ for: 'enterprise_phone' } {{'enterprise.registration.modal.steps.contact.phone_field' | t}}:
- %input.chunky.small-12.columns{ id: 'enterprise_phone', name: 'phone', placeholder: "{{'enterprise.registration.modal.steps.contact.phone_field_placeholder' | t}}", ng: { model: 'enterprise.phone' } }
+ %label{ for: 'enterprise_phone' }= t(".phone_field")+":"
+ %input.chunky.small-12.columns{ id: 'enterprise_phone', name: 'phone', placeholder: "{{'registration.steps.contact.phone_field_placeholder' | t}}", ng: { model: 'enterprise.phone' } }
.small-12.medium-12.large-5.hide-for-small-only
.row.buttons
diff --git a/app/views/registration/steps/_details.html.haml b/app/views/registration/steps/_details.html.haml
index 4fce6a4319..6639919830 100644
--- a/app/views/registration/steps/_details.html.haml
+++ b/app/views/registration/steps/_details.html.haml
@@ -4,60 +4,59 @@
.row
.small-12.columns
%header
- %h2 {{'enterprise.registration.modal.steps.details.headline' | t}}
- %h5{ ng: { if: "::enterprise.type != 'own'" } } {{'enterprise.registration.modal.steps.details.enterprise' | t}}
- %h5{ ng: { if: "::enterprise.type == 'own'" } } {{'enterprise.registration.modal.steps.details.producer' | t}}
+ %h2= t('.headline')
+ %h5{ ng: { if: "::enterprise.type != 'own'" } }= t(".enterprise")
+ %h5{ ng: { if: "::enterprise.type == 'own'" } }= t(".producer")
%form{ name: 'details', novalidate: true, ng: { controller: "RegistrationFormCtrl", submit: "selectIfValid('contact',details)" } }
.row
.small-12.medium-9.large-12.columns.end
.field
- %label{ for: 'enterprise_name', ng: { if: "::enterprise.type != 'own'" } } {{'enterprise.registration.modal.steps.details.enterprise_name_field' | t}}
- %label{ for: 'enterprise_name', ng: { if: "::enterprise.type == 'own'" } } {{'enterprise.registration.modal.steps.details.producer_name_field' | t}}
- %input.chunky{ id: 'enterprise_name', name: 'name', placeholder: "{{'enterprise.registration.modal.steps.details.producer_name_field_placeholder' | t}}", required: true, ng: { model: 'enterprise.name' } }
+ %label{ for: 'enterprise_name', ng: { if: "::enterprise.type != 'own'" } }= t(".enterprise_name_field")
+ %label{ for: 'enterprise_name', ng: { if: "::enterprise.type == 'own'" } }= t(".producer_name_field")
+ %input.chunky{ id: 'enterprise_name', name: 'name', placeholder: "{{'registration.steps.details.producer_name_field_placeholder' | t}}", required: true, ng: { model: 'enterprise.name' } }
%span.error{ ng: { show: "details.name.$error.required && submitted" } }
- {{'enterprise.registration.modal.steps.details.producer_name_field_error' | t}}
+ = t(".producer_name_field_error")
.row
.small-12.medium-9.large-6.columns
.field
- %label{ for: 'enterprise_address' } {{'enterprise.registration.modal.steps.details.address1_field' | t}}
- %input.chunky{ id: 'enterprise_address', name: 'address1', required: true, placeholder: "{{'enterprise.registration.modal.steps.details.address1_field_placeholder' | t}}", required: true, ng: { model: 'enterprise.address.address1' } }
+ %label{ for: 'enterprise_address' }= t(".address1_field")
+ %input.chunky{ id: 'enterprise_address', name: 'address1', required: true, placeholder: "{{'registration.steps.details.address1_field_placeholder' | t}}", required: true, ng: { model: 'enterprise.address.address1' } }
%span.error{ ng: { show: "details.address1.$error.required && submitted" } }
- {{'enterprise.registration.modal.steps.details.address1_field_error' | t}}
+ = t(".address1_field_error")
.field
- %label{ for: 'enterprise_address2' } {{'enterprise.registration.modal.steps.details.address2_field' | t}}
+ %label{ for: 'enterprise_address2' }= t(".address2_field")
%input.chunky{ id: 'enterprise_address2', name: 'address2', required: false, placeholder: "", required: false, ng: { model: 'enterprise.address.address2' } }
.small-12.medium-9.large-6.columns.end
.row
.small-12.medium-8.large-8.columns
.field
- %label{ for: 'enterprise_city' } {{'enterprise.registration.modal.steps.details.suburb_field' | t}}
- %input.chunky{ id: 'enterprise_city', name: 'city', required: true, placeholder: "{{'enterprise.registration.modal.steps.details.suburb_field_placeholder' | t}}", ng: { model: 'enterprise.address.city' } }
+ %label{ for: 'enterprise_city' }= t('.suburb_field')
+ %input.chunky{ id: 'enterprise_city', name: 'city', required: true, placeholder: "{{'registration.steps.details.suburb_field_placeholder' | t}}", ng: { model: 'enterprise.address.city' } }
%span.error{ ng: { show: "details.city.$error.required && submitted" } }
- {{'enterprise.registration.modal.steps.details.suburb_field_error' | t}}
+ = t(".suburb_field_error")
.small-12.medium-4.large-4.columns
.field
- %label{ for: 'enterprise_zipcode' } {{'enterprise.registration.modal.steps.details.postcode_field' | t}}
- %input.chunky{ id: 'enterprise_zipcode', name: 'zipcode', required: true, placeholder: "{{'enterprise.registration.modal.steps.details.postcode_field_placeholder' | t}}", ng: { model: 'enterprise.address.zipcode' } }
+ %label{ for: 'enterprise_zipcode' }= t(".postcode_field")
+ %input.chunky{ id: 'enterprise_zipcode', name: 'zipcode', required: true, placeholder: "{{'registration.steps.details.postcode_field_placeholder' | t}}", ng: { model: 'enterprise.address.zipcode' } }
%span.error{ ng: { show: "details.zipcode.$error.required && submitted" } }
- {{'enterprise.registration.modal.steps.details.postcode_field_error' | t}}
+ = t(".postcode_field_error")
.row
.small-12.medium-4.large-4.columns
.field
- %label{ for: 'enterprise_state' } {{'enterprise.registration.modal.steps.details.state_field' | t}}
+ %label{ for: 'enterprise_state' }= t(".state_field")
%select.chunky{ id: 'enterprise_state', name: 'state', ng: { model: 'enterprise.address.state_id', options: 's.id as s.abbr for s in enterprise.country.states', show: 'countryHasStates()', required: 'countryHasStates()' } }
%span.error{ ng: { show: "details.state.$error.required && submitted" } }
- {{'enterprise.registration.modal.steps.details.state_field_error' | t}}
+ = t(".state_field_error")
.small-12.medium-8.large-8.columns
.field
- %label{ for: 'enterprise_country' } {{'enterprise.registration.modal.steps.details.country_field' | t}}
+ %label{ for: 'enterprise_country' }= t(".country_field")
%select.chunky{ id: 'enterprise_country', name: 'country', required: true, ng: { init: "setDefaultCountry(#{Spree::Config[:default_country_id]})", model: 'enterprise.country', options: 'c as c.name for c in countries' } }
%span.error{ ng: { show: "details.country.$error.required && submitted" } }
- {{'enterprise.registration.modal.steps.details.country_field_error' | t}}
-
+ = t(".country_field_error")
.row.buttons
.small-12.columns
diff --git a/app/views/registration/steps/_finished.html.haml b/app/views/registration/steps/_finished.html.haml
index 96ed600147..d22384dbdb 100644
--- a/app/views/registration/steps/_finished.html.haml
+++ b/app/views/registration/steps/_finished.html.haml
@@ -3,10 +3,10 @@
.row
.small-12.columns.pad-top
%header
- %h2 {{'registration_finished_headline' | t}}
+ %h2= t(".headline")
.panel.callout
- %p{ "ng-bind" => "'registration_finished_thanks' | t:{enterprise: enterprise.name}" }
- %p {{'registration_finished_login' | t}}
+ %p{ "ng-bind" => "'registration.steps.finished.thanks' | t:{enterprise: enterprise.name}" }
+ %p= t(".login")
.row
.small-12.columns.text-center
- %a.button.primary{ type: "button", href: "/" } {{'registration_finished_action' | t}} >
+ %a.button.primary{ type: "button", href: "/" }= "#{t(".action")} >"
diff --git a/app/views/registration/steps/_introduction.html.haml b/app/views/registration/steps/_introduction.html.haml
index f973ca055a..84bbb9840e 100644
--- a/app/views/registration/steps/_introduction.html.haml
+++ b/app/views/registration/steps/_introduction.html.haml
@@ -2,35 +2,35 @@
.row
.small-12.columns
%header
- %h2 {{'registration_greeting' | t}}
+ %h2= t(".registration_greeting")
%h4
%small
%i.ofn-i_040-hub
- {{'registration_intro' | t}}
+ = t(".registration_intro")
.row{ 'data-equalizer' => true }
.small-12.medium-12.large-6.columns.pad-top{ 'data-equalizer-watch' => true }
- %h5 {{'registration_checklist' | t}}:
+ %h5= t(".registration_checklist")+":"
%ul.check-list
%li
- {{'registration_time' | t}}
+ = t(".registration_time")
%li
- {{'registration_enterprise_address' | t}}
+ = t(".registration_enterprise_address")
%li
- {{'registration_contact_details' | t}}
+ = t(".registration_contact_details")
%li
- {{'registration_logo' | t}}
+ = t(".registration_logo")
%li
- {{'registration_promo_image' | t}}
+ = t(".registration_promo_image")
%li
- {{'registration_about_us' | t}}
+ = t(".registration_about_us")
.small-9.medium-8.large-5.columns.pad-top.end{ 'data-equalizer-watch' => true}
%h5
- {{'registration_outcome_headline' | t}}
- %p{ "ng-bind-html" => "t('registration_outcome1_html')" }
- %p {{'registration_outcome2' | t}}
- %p {{'registration_outcome3' | t}}
+ = t(".registration_outcome_headline")
+ %p= t(".registration_outcome1_html")
+ %p= t(".registration_outcome2")
+ %p= t(".registration_outcome3")
.row{'ng-init' => "tos_required=#{Spree::Config.enterprises_require_tos}" }
%hr
@@ -43,4 +43,4 @@
%label{for: "accept_terms"} #{t(:enterprise_tos_agree)}
.small-12.medium-6.columns
- %input.button.primary.left{ type: "button", value: "{{'registration_action' | t}}", ng: { click: "select('details')", disabled: "tos_required && !tos_accepted", model: "tos_accepted"} }
+ %input.button.primary.left{ type: "button", value: "{{'registration.steps.introduction.registration_action' | t}}", ng: { click: "select('details')", disabled: "tos_required && !tos_accepted", model: "tos_accepted"} }
diff --git a/app/views/registration/steps/_limit_reached.html.haml b/app/views/registration/steps/_limit_reached.html.haml
index 44f3b53f22..c8fa25a43c 100644
--- a/app/views/registration/steps/_limit_reached.html.haml
+++ b/app/views/registration/steps/_limit_reached.html.haml
@@ -2,16 +2,16 @@
.row
.small-12.columns
%header
- %h2 {{'limit_reached_headline' | t}}
- %h4 {{'limit_reached_message' | t}}
+ %h2= t(".headline")
+ %h4= t(".message")
.row
.small-12.medium-3.large-2.columns.text-right.hide-for-small-only
%img{:src => "/assets/potatoes.png"}
.small-12.medium-9.large-10.columns
%p
- {{'limit_reached_text' | t}}
+ = t(".text")
%strong Open Food Network.
.row
.small-12.columns
%hr
- %input.button.primary{ type: "button", value: "{{'limit_reached_action' | t}}", ng: { click: "close()" } }
+ %input.button.primary{ type: "button", value: "{{'registration.steps.limit_reached.action' | t}}", ng: { click: "close()" } }
diff --git a/app/views/registration/steps/_logo.html.haml b/app/views/registration/steps/_logo.html.haml
index 3d1effdf93..677653b4bb 100644
--- a/app/views/registration/steps/_logo.html.haml
+++ b/app/views/registration/steps/_logo.html.haml
@@ -5,42 +5,42 @@
.row
.small-12.columns.center
%h4
- {{'select_logo' | t}}
+ = t(".select_logo")
.row
.small-12.columns.center
%span.small
- {{'logo_tip' | t}}
+ = t(".logo_tip")
.row.pad-top
.small-12.columns
.image-select.small-12.columns
- %label.small-12.columns.button{ for: 'image-select' } {{'logo_label' | t}}
+ %label.small-12.columns.button{ for: 'image-select' }= t(".logo_label")
%input#image-select{ type: 'file', hidden: true, 'nv-file-select' => true, uploader: "imageUploader", options: '{ alias: imageStep }' }
.row.show-for-large-up
.large-12.columns
%span#or.large-12.columns
- {{'action_or' | t}}
+ = t("action_or")
.row.show-for-large-up
.large-12.columns
#image-over{ 'nv-file-over' => true, uploader: "imageUploader" }
- {{'logo_drag' | t}}
+ = t(".logo_drag")
.small-12.medium-12.large-6.columns
.row
.small-12.columns.center
.row
.small-12.columns.center
%h4
- {{'review_logo' | t}}
+ = t(".review_logo")
.row
.small-12.columns.center
%span.small
- {{'review_logo_tip' | t}}
+ = t(".review_logo_tip")
.row.pad-top
.small-12.columns.center
#image-placeholder.logo
%img{ ng: { show: "imageSrc() && !imageUploader.isUploading", src: '{{ imageSrc() }}' } }
.message{ ng: { hide: "imageSrc() || imageUploader.isUploading" } }
- {{'logo_placeholder' | t}}
+ = t(".logo_placeholder")
.loading{ ng: { hide: "!imageUploader.isUploading" } }
%img.spinner{ src: "/assets/spinning-circles.svg" }
%br/
- {{'uploading' | t}}
+ = t("registration.steps.images.uploading")
diff --git a/app/views/registration/steps/_promo.html.haml b/app/views/registration/steps/_promo.html.haml
index 0b224e1f64..91a8bc9a78 100644
--- a/app/views/registration/steps/_promo.html.haml
+++ b/app/views/registration/steps/_promo.html.haml
@@ -3,42 +3,42 @@
.row
.small-12.columns.center
%h4
- {{'select_promo_image' | t}}
+ = t(".select_promo_image")
.row
.small-12.medium-12.large-5.columns.center
.row
.small-12.columns.center
%span.small
- {{'promo_image_tip' | t}}
+ = t(".promo_image_tip")
.row.pad-top
.small-12.columns
.image-select.small-12.columns
- %label.small-12.columns.button{ for: 'image-select' } {{'promo_image_label' | t}}
+ %label.small-12.columns.button{ for: 'image-select' }= t(".promo_image_label")
%input#image-select{ type: 'file', hidden: true, 'nv-file-select' => true, uploader: "imageUploader", options: '{ alias: imageStep }' }
.large-2.columns
%span#or.horizontal.large-12.columns
- {{'action_or' | t}}
+ = t("action_or")
.large-5.columns
#image-over{ 'nv-file-over' => true, uploader: "imageUploader" }
- {{'promo_image_drag' | t}}
+ = t(".promo_image_drag")
.small-12.medium-12.large-12.columns.pad-top
.row
.small-12.columns.center
%h4
- {{'review_promo_image' | t}}
+ = t(".review_promo_image")
.row
.small-12.columns.center
.row
.small-12.columns.center
%span.small
- {{'review_promo_image_tip' | t}}
+ = t(".review_promo_image_tip")
.row.pad-top
.small-12.columns.center
#image-placeholder.promo
%img{ ng: { show: "imageSrc() && !imageUploader.isUploading", src: '{{ imageSrc() }}' } }
.message{ ng: { hide: "imageSrc() || imageUploader.isUploading" } }
- {{'promo_image_placeholder' | t}}
+ = t(".promo_image_placeholder")
.loading{ ng: { hide: "!imageUploader.isUploading" } }
%img.spinner{ src: "/assets/spinning-circles.svg" }
%br/
- {{'uploading' | t}}
+ = t("registration.steps.images.uploading")
diff --git a/app/views/registration/steps/_social.html.haml b/app/views/registration/steps/_social.html.haml
index edbdd94dd9..8552b927b7 100644
--- a/app/views/registration/steps/_social.html.haml
+++ b/app/views/registration/steps/_social.html.haml
@@ -5,8 +5,8 @@
.row
.small-12.columns
%header
- %h2 {{'enterprise_final_step' | t}}
- %h5{ "ng-bind" => "'enterprise_social_text' | t:{enterprise: enterprise.name}" }
+ %h2= t(".enterprise_final_step")
+ %h5{ "ng-bind" => "'registration.steps.social.enterprise_social_text' | t:{enterprise: enterprise.name}" }
%form{ name: 'social', novalidate: true, ng: { controller: "RegistrationFormCtrl", submit: "update('finished',social)" } }
.row.content
@@ -14,29 +14,29 @@
.row
.small-12.columns
.field
- %label{ for: 'enterprise_website' } {{'website' | t}}:
- %input.chunky{ id: 'enterprise_website', placeholder: "{{'website_placeholder' | t}}", ng: { model: 'enterprise.website' } }
+ %label{ for: 'enterprise_website' }= t(".website")+":"
+ %input.chunky{ id: 'enterprise_website', placeholder: "{{'registration.steps.social.website_placeholder' | t}}", ng: { model: 'enterprise.website' } }
.row
.small-12.columns
.field
- %label{ for: 'enterprise_facebook' } {{'facebook' | t}}:
- %input.chunky{ id: 'enterprise_facebook', placeholder: "{{'facebook_placeholder' | t}}", ng: { model: 'enterprise.facebook' } }
+ %label{ for: 'enterprise_facebook' }= t(".facebook")+":"
+ %input.chunky{ id: 'enterprise_facebook', placeholder: "{{'registration.steps.social.facebook_placeholder' | t}}", ng: { model: 'enterprise.facebook' } }
.row
.small-12.columns
.field
- %label{ for: 'enterprise_linkedin' } {{'linkedin' | t}}:
- %input.chunky{ id: 'enterprise_linkedin', placeholder: "{{'linkedin_placeholder' | t}}", ng: { model: 'enterprise.linkedin' } }
+ %label{ for: 'enterprise_linkedin' }= t(".linkedin")+":"
+ %input.chunky{ id: 'enterprise_linkedin', placeholder: "{{'registration.steps.social.linkedin_placeholder' | t}}", ng: { model: 'enterprise.linkedin' } }
.small-12.large-5.columns
.row
.small-12.columns
.field
- %label{ for: 'enterprise_twitter' } {{'twitter' | t}}:
- %input.chunky{ id: 'enterprise_twitter', placeholder: "{{'twitter_placeholder' | t}}", ng: { model: 'enterprise.twitter' } }
+ %label{ for: 'enterprise_twitter' }= t(".twitter")+":"
+ %input.chunky{ id: 'enterprise_twitter', placeholder: "{{'registration.steps.social.twitter_placeholder' | t}}", ng: { model: 'enterprise.twitter' } }
.row
.small-12.columns
.field
- %label{ for: 'enterprise_instagram' } {{'instagram' | t}}:
- %input.chunky{ id: 'enterprise_instagram', placeholder: "{{'instagram_placeholder' | t}}", ng: { model: 'enterprise.instagram' } }
+ %label{ for: 'enterprise_instagram' }= t(".instagram")+":"
+ %input.chunky{ id: 'enterprise_instagram', placeholder: "{{'registration.steps.social.instagram_placeholder' | t}}", ng: { model: 'enterprise.instagram' } }
.row.buttons
.small-12.columns
diff --git a/app/views/registration/steps/_steps.html.haml b/app/views/registration/steps/_steps.html.haml
index 3538d5ff48..081cd97d98 100644
--- a/app/views/registration/steps/_steps.html.haml
+++ b/app/views/registration/steps/_steps.html.haml
@@ -1,5 +1,5 @@
%script{ type: "text/ng-template", id: "registration/steps.html" }
.row#progress-bar
.small-12.medium-2.columns.item{ ng: { repeat: 'step in steps', class: "{active: (currentStep() == step),'show-for-medium-up': (currentStep() != step)}" } }
- {{ $index+1 + ". " + ('enterprise.registration.modal.steps.' + step + '.title' | t) }}
+ {{ $index+1 + ". " + ('registration.steps.' + step + '.title' | t) }}
diff --git a/config/locales/en.yml b/config/locales/en.yml
index fc1595d709..486e5cb6e3 100644
--- a/config/locales/en.yml
+++ b/config/locales/en.yml
@@ -1867,24 +1867,60 @@ See the %{link} to find out more about %{sitename}'s features and to start using
choose_password: "Choose a password"
confirm_password: "Confirm password"
action_signup: "Sign up now"
- welcome_to_ofn: "Welcome to the Open Food Network!"
- signup_or_login: "Start By Signing Up (or logging in)"
- have_an_account: "Already have an account?"
- action_login: "Log in now."
forgot_password: "Forgot Password?"
password_reset_sent: "An email with instructions on resetting your password has been sent!"
reset_password: "Reset password"
- registration_greeting: "Greetings!"
- who_is_managing_enterprise: "Who is responsible for managing %{enterprise}?"
update_and_recalculate_fees: "Update And Recalculate Fees"
registration:
steps:
- images:
- continue: "Continue"
- back: "Back"
- headline: "Thanks!"
- description: "Let's upload some pretty pictures so your profile looks great! :)"
+ introduction:
+ registration_greeting: "Hi there!"
+ registration_intro: "You can now create a profile for your Producer or Hub"
+ registration_checklist: "You'll need"
+ registration_time: "5-10 minutes"
+ registration_enterprise_address: "Enterprise address"
+ registration_contact_details: "Primary contact details"
+ registration_logo: "Your logo image"
+ registration_promo_image: "Landscape image for your profile"
+ registration_about_us: "'About Us' text"
+ registration_outcome_headline: "What do I get?"
+ registration_outcome1_html: "Your profile helps people find and contact you on the Open Food Network."
+ registration_outcome2: "Use this space to tell the story of your enterprise, to help drive connections to your social and online presence."
+ registration_outcome3: "It's also the first step towards trading on the Open Food Network, or opening an online store."
+ registration_action: "Let's get started!"
+ details:
+ title: "Details"
+ headline: "Let's Get Started"
+ enterprise: "Woot! First need to know a little bit about your enterprise:"
+ producer: "Woot! First we need to know a little bit about your farm:"
+ enterprise_name_field: "Enterprise Name:"
+ producer_name_field: "Farm Name:"
+ producer_name_field_placeholder: "e.g. Charlie's Awesome Farm"
+ producer_name_field_error: "Please choose a unique name for your enterprise"
+ address1_field: "Address line 1:"
+ address1_field_placeholder: "e.g. 123 Cranberry Drive"
+ address1_field_error: "Please enter an address"
+ address2_field: "Address line 2:"
+ suburb_field: "Suburb:"
+ suburb_field_placeholder: "e.g. Northcote"
+ suburb_field_error: "Please enter a suburb"
+ postcode_field: "Postcode:"
+ postcode_field_placeholder: "e.g. 3070"
+ postcode_field_error: "Postcode required"
+ state_field: "State:"
+ state_field_error: "State required"
+ country_field: "Country:"
+ country_field_error: "Please select a country"
+ contact:
+ title: "Contact"
+ who_is_managing_enterprise: "Who is responsible for managing %{enterprise}?"
+ contact_field: "Primary Contact"
+ contact_field_placeholder: "Contact Name"
+ contact_field_required: "You need to enter a primary contact."
+ phone_field: "Phone number"
+ phone_field_placeholder: "eg. (03) 1234 5678"
type:
+ title: "Type"
headline: "Last step to add %{enterprise}!"
question: "Are you a producer?"
yes_producer: "Yes, I'm a producer"
@@ -1893,161 +1929,75 @@ See the %{link} to find out more about %{sitename}'s features and to start using
yes_producer_help: "Producers make yummy things to eat and/or drink. You're a producer if you grow it, raise it, brew it, bake it, ferment it, milk it or mould it."
no_producer_help: "If you’re not a producer, you’re probably someone who sells and distributes food. You might be a hub, coop, buying group, retailer, wholesaler or other."
create_profile: "Create Profile"
- enterprise:
- registration:
- modal:
- steps:
- details:
- title: 'Details'
- headline: "Let's Get Started"
- enterprise: "Woot! First we need to know a little bit about your enterprise:"
- producer: "Woot! First we need to know a little bit about your farm:"
- enterprise_name_field: "Enterprise Name:"
- producer_name_field: "Farm Name:"
- producer_name_field_placeholder: "e.g. Charlie's Awesome Farm"
- producer_name_field_error: "Please choose a unique name for your enterprise"
- address1_field: "Address line 1:"
- address1_field_placeholder: "e.g. 123 Cranberry Drive"
- address1_field_error: "Please enter an address"
- address2_field: "Address line 2:"
- suburb_field: "Suburb:"
- suburb_field_placeholder: "e.g. Northcote"
- suburb_field_error: "Please enter a suburb"
- postcode_field: "Postcode:"
- postcode_field_placeholder: "e.g. 3070"
- postcode_field_error: "Postcode required"
- state_field: "State:"
- state_field_error: "State required"
- country_field: "Country:"
- country_field_error: "Please select a country"
- contact:
- title: 'Contact'
- contact_field: 'Primary Contact'
- contact_field_placeholder: 'Contact Name'
- contact_field_required: "You need to enter a primary contact."
- email_field: 'Email address'
- email_field_placeholder: 'eg. charlie@thefarm.com'
- phone_field: 'Phone number'
- phone_field_placeholder: 'eg. (03) 1234 5678'
- type:
- title: 'Type'
- about:
- title: 'About'
- images:
- title: 'Images'
- social:
- title: 'Social'
- # TODO: Remove these once the enterprise.registration.modal keys are translated
- enterprise_contact: "Primary Contact"
- enterprise_contact_placeholder: "Contact Name"
- enterprise_contact_required: "You need to enter a primary contact."
- enterprise_email_address: "Email address"
- enterprise_email_placeholder: "eg. charlie@thefarm.com"
- enterprise_phone: "Phone number"
- enterprise_phone_placeholder: "eg. (03) 1234 5678"
- # END
+ about:
+ title: "About"
+ headline: "Nice one!"
+ message: "Now let's flesh out the details about"
+ success: "Success! %{enterprise} added to the Open Food Network"
+ registration_exit_message: "If you exit this wizard at any stage, you can continue to create your profile by going to the admin interface."
+ enterprise_description: "Short Description"
+ enterprise_description_placeholder: "A short sentence describing your enterprise"
+ enterprise_long_desc: "Long Description"
+ enterprise_long_desc_placeholder: "This is your opportunity to tell the story of your enterprise - what makes you different and wonderful? We'd suggest keeping your description to under 600 characters or 150 words."
+ enterprise_long_desc_length: "%{num} characters / up to 600 recommended"
+ enterprise_abn: "ABN"
+ enterprise_abn_placeholder: "eg. 99 123 456 789"
+ enterprise_acn: "ACN"
+ enterprise_acn_placeholder: "eg. 123 456 789"
+ enterprise_tax_required: "You need to make a selection."
+ images:
+ title: "Images"
+ headline: "Thanks!"
+ description: "Let's upload some pretty pictures so your profile looks great! :)"
+ uploading: "Uploading..."
+ continue: "Continue"
+ back: "Back"
+ logo:
+ select_logo: "Step 1. Select Logo Image"
+ logo_tip: "Tip: Square images will work best, preferably at least 300×300px"
+ logo_label: "Choose a logo image"
+ logo_drag: "Drag and drop your logo here"
+ review_logo: "Step 2. Review Your Logo"
+ review_logo_tip: "Tip: for best results, your logo should fill the available space"
+ logo_placeholder: "Your logo will appear here for review once uploaded"
+ promo:
+ select_promo_image: "Step 3. Select Promo Image"
+ promo_image_tip: "Tip: Shown as a banner, preferred size is 1200×260px"
+ promo_image_label: "Choose a promo image"
+ promo_image_drag: "Drag and drop your promo here"
+ review_promo_image: "Step 4. Review Your Promo Banner"
+ review_promo_image_tip: "Tip: for best results, your promo image should fill the available space"
+ promo_image_placeholder: "Your logo will appear here for review once uploaded"
+ social:
+ title: "Social"
+ enterprise_final_step: "Final step!"
+ enterprise_social_text: "How can people find %{enterprise} online?"
+ website: "Website"
+ website_placeholder: "eg. openfoodnetwork.org.au"
+ facebook: "Facebook"
+ facebook_placeholder: "eg. www.facebook.com/PageNameHere"
+ linkedin: "LinkedIn"
+ linkedin_placeholder: "eg. www.linkedin.com/YourNameHere"
+ twitter: "Twitter"
+ twitter_placeholder: "eg. @twitter_handle"
+ instagram: "Instagram"
+ instagram_placeholder: "eg. @instagram_handle"
+ limit_reached:
+ headline: "Oh no!"
+ message: "You have reached the limit!"
+ text: "You have reached the limit for the number of enterprises you are allowed to own on the"
+ action: "Return to the homepage"
+ finished:
+ headline: "Finished!"
+ thanks: "Thanks for filling out the details for %{enterprise}."
+ login: "You can change or update your enterprise at any stage by logging into Open Food Network and going to Admin."
+ action: "Open Food Network home"
+
back: "Back"
continue: "Continue"
- limit_reached_headline: "Oh no!"
- limit_reached_message: "You have reached the limit!"
- limit_reached_text: "You have reached the limit for the number of enterprises you are allowed to own on the"
- limit_reached_action: "Return to the homepage"
- select_promo_image: "Step 3. Select Promo Image"
- promo_image_tip: "Tip: Shown as a banner, preferred size is 1200×260px"
- promo_image_label: "Choose a promo image"
action_or: "OR"
- promo_image_drag: "Drag and drop your promo here"
- review_promo_image: "Step 4. Review Your Promo Banner"
- review_promo_image_tip: "Tip: for best results, your promo image should fill the available space"
- promo_image_placeholder: "Your logo will appear here for review once uploaded"
- uploading: "Uploading..."
- select_logo: "Step 1. Select Logo Image"
- logo_tip: "Tip: Square images will work best, preferably at least 300×300px"
- logo_label: "Choose a logo image"
- logo_drag: "Drag and drop your logo here"
- review_logo: "Step 2. Review Your Logo"
- review_logo_tip: "Tip: for best results, your logo should fill the available space"
- logo_placeholder: "Your logo will appear here for review once uploaded"
- enterprise_about_headline: "Nice one!"
- enterprise_about_message: "Now let's flesh out the details about"
- enterprise_success: "Success! %{enterprise} added to the Open Food Network "
- enterprise_registration_exit_message: "If you exit this wizard at any stage, you can continue to create your profile by going to the admin interface."
- enterprise_description: "Short Description"
- enterprise_description_placeholder: "A short sentence describing your enterprise"
- enterprise_long_desc: "Long Description"
- enterprise_long_desc_placeholder: "This is your opportunity to tell the story of your enterprise - what makes you different and wonderful? We'd suggest keeping your description to under 600 characters or 150 words."
- enterprise_long_desc_length: "%{num} characters / up to 600 recommended"
- enterprise_abn: "ABN"
- enterprise_abn_placeholder: "eg. 99 123 456 789"
- enterprise_acn: "ACN"
- enterprise_acn_placeholder: "eg. 123 456 789"
- enterprise_tax_required: "You need to make a selection."
- enterprise_final_step: "Final step!"
- enterprise_social_text: "How can people find %{enterprise} online?"
- website: "Website"
- website_placeholder: "eg. openfoodnetwork.org.au"
- facebook: "Facebook"
- facebook_placeholder: "eg. www.facebook.com/PageNameHere"
- linkedin: "LinkedIn"
- linkedin_placeholder: "eg. www.linkedin.com/YourNameHere"
- twitter: "Twitter"
- twitter_placeholder: "eg. @twitter_handle"
- instagram: "Instagram"
- instagram_placeholder: "eg. @instagram_handle"
- registration_greeting: "Hi there!"
- registration_intro: "You can now create a profile for your Producer or Hub"
- registration_action: "Let's get started!"
- registration_checklist: "You'll need"
- registration_time: "5-10 minutes"
- registration_enterprise_address: "Enterprise address"
- registration_contact_details: "Primary contact details"
- registration_logo: "Your logo image"
- registration_promo_image: "Landscape image for your profile"
- registration_about_us: "'About Us' text"
- registration_outcome_headline: "What do I get?"
- registration_outcome1_html: "Your profile helps people find and contact you on the Open Food Network."
- registration_outcome2: "Use this space to tell the story of your enterprise, to help drive connections to your social and online presence. "
- registration_outcome3: "It's also the first step towards trading on the Open Food Network, or opening an online store."
- registration_finished_headline: "Finished!"
- registration_finished_thanks: "Thanks for filling out the details for %{enterprise}."
- registration_finished_login: "You can change or update your enterprise at any stage by logging into Open Food Network and going to Admin."
- registration_finished_action: "Open Food Network home"
- registration_contact_name: 'Contact Name'
+ enterprise_limit: Enterprise Limit
- # TODO: Remove these once the enterprise.registration.modal keys are translated
- registration_type_headline: "Last step to add %{enterprise}!"
- registration_type_question: "Are you a producer?"
- registration_type_producer: "Yes, I'm a producer"
- registration_type_no_producer: "No, I'm not a producer"
- registration_type_error: "Please choose one. Are you are producer?"
- registration_type_producer_help: "Producers make yummy things to eat and/or drink. You're a producer if you grow it, raise it, brew it, bake it, ferment it, milk it or mould it."
- registration_type_no_producer_help: "If you’re not a producer, you’re probably someone who sells and distributes food. You might be a hub, coop, buying group, retailer, wholesaler or other."
- # END
-
-
- # TODO: Remove these once the enterprise.registration.modal keys are translated
- registration_detail_headline: "Let's Get Started"
- registration_detail_enterprise: "Woot! First we need to know a little bit about your enterprise:"
- registration_detail_producer: "Woot! First we need to know a little bit about your farm:"
- registration_detail_name_enterprise: "Enterprise Name:"
- registration_detail_name_producer: "Farm Name:"
- registration_detail_name_placeholder: "e.g. Charlie's Awesome Farm"
- registration_detail_name_error: "Please choose a unique name for your enterprise"
- registration_detail_address1: "Address line 1:"
- registration_detail_address1_placeholder: "e.g. 123 Cranberry Drive"
- registration_detail_address1_error: "Please enter an address"
- registration_detail_address2: "Address line 2:"
- registration_detail_suburb: "Suburb:"
- registration_detail_suburb_placeholder: "e.g. Northcote"
- registration_detail_suburb_error: "Please enter a suburb"
- registration_detail_postcode: "Postcode:"
- registration_detail_postcode_placeholder: "e.g. 3070"
- registration_detail_postcode_error: "Postcode required"
- registration_detail_state: "State:"
- registration_detail_state_error: "State required"
- registration_detail_country: "Country:"
- registration_detail_country_error: "Please select a country"
- # END
shipping_method_destroy_error: "That shipping method cannot be deleted as it is referenced by an order: %{number}."
accounts_and_billing_task_already_running_error: "A task is already running, please wait until it has finished"
accounts_and_billing_start_task_notice: "Task Queued"
@@ -2687,6 +2637,12 @@ See the %{link} to find out more about %{sitename}'s features and to start using
closes: closes
closed: closed
close_date_not_set: Close date not set
+ registration:
+ welcome_to_ofn: "Welcome to the Open Food Network!"
+ signup_or_login: "Start By Signing Up (or logging in)"
+ have_an_account: "Already have an account?"
+ action_login: "Log in now."
+
producers:
signup:
start_free_profile: "Start with a free profile, and expand when you're ready!"
diff --git a/spec/features/consumer/registration_spec.rb b/spec/features/consumer/registration_spec.rb
index 0a7756d104..efbb9deca0 100644
--- a/spec/features/consumer/registration_spec.rb
+++ b/spec/features/consumer/registration_spec.rb
@@ -139,7 +139,7 @@ feature "Registration", js: true do
fill_in "Email", with: user.email
fill_in "Password", with: user.password
click_button 'Login'
- expect(page).to have_content I18n.t('limit_reached_headline')
+ expect(page).to have_content I18n.t('registration.steps.limit_reached.headline')
end
end
end