Skip to content

Commit

Permalink
Add missing translations on the take/edit questionnaire page
Browse files Browse the repository at this point in the history
  • Loading branch information
tonymarklove committed Sep 23, 2015
1 parent 6852b52 commit 7393473
Show file tree
Hide file tree
Showing 5 changed files with 36 additions and 32 deletions.
5 changes: 3 additions & 2 deletions app/views/partials/_question.html.haml
Original file line number Diff line number Diff line change
Expand Up @@ -51,7 +51,7 @@

- if all_autocompleted
- state = 'autocompleted-url-warning'
- status_message = t('surveyor.autocomplete_url_warning')
- status_message = t('surveyor.autocompleted_url_warning')

- if r.any_metadata_missing(@responses)
- state = 'metadata-missing'
Expand Down Expand Up @@ -140,6 +140,7 @@
%p
!= q.help_text_for(@render_context, I18n.locale)
- if (q.help_text_more_url)
%a{:href => q.help_text_more_url} Read more...
%a{:href => q.help_text_more_url}
= t('surveyor.question_comment_read_more')
- if q.discussion_topic
= comment_link q.discussion_topic, t('surveyor.question_comment'), q.text, q.id
7 changes: 4 additions & 3 deletions app/views/surveyor/edit.html.haml
Original file line number Diff line number Diff line change
Expand Up @@ -20,13 +20,13 @@
.row
.span9
.jurisdiction
Jurisdiction:
= t('surveys.jurisdiction')
.badge.badge-inverse= @response_set.survey.complete_title
%span.status= @survey.try(:status)
= link_to "#switch-#{@response_set.id}", data: {toggle: :modal, content: t('dashboard.popover.change_jurisdiction') }, class: 'popdown' do
%i.icon.icon-pencil
- if @survey.translations.count > 1
Language:
= t('surveys.language')
.badge.badge-inverse= @response_set.locale_name
= link_to "#switch-language-#{@response_set.id}", data:{toggle: :modal} do
%i.icon.icon-pencil
Expand Down Expand Up @@ -69,7 +69,8 @@
.span8.lead
!= @survey.intro
%p
%a{href: about_url} Read more about Open Data Certificates
%a{href: about_url}
= t('surveys.read_more')


.documentation-url
Expand Down
19 changes: 9 additions & 10 deletions app/views/surveyor/start.html.haml
Original file line number Diff line number Diff line change
Expand Up @@ -16,13 +16,13 @@
.row
.span9
.jurisdiction
= t('surveys.start.jurisdiction')
= t('surveys.jurisdiction')
.badge.badge-inverse= @response_set.jurisdiction
%span.status= @survey.try(:status)
= link_to "#switch-#{@response_set.id}", data: {toggle: :modal, content: t('dashboard.popover.change_jurisdiction') }, class: 'popdown' do
%i.icon.icon-pencil
- if @survey.translations.count > 1
= t('surveys.start.language')
= t('surveys.language')
.badge.badge-inverse= @response_set.locale_name
= link_to "#switch-language-#{@response_set.id}", data:{toggle: :modal} do
%i.icon.icon-pencil
Expand All @@ -35,14 +35,14 @@
.alert.alert-alert.flash{"data-dismiss" => "alert"}
%i.icon-exclamation-sign.icon-large.icon-white
%button.icon-remove{"data-dismiss" => "alert", :type => "button"}
= t('surveys.start.url_problem_error')
= t('surveys.url_problem_error')
.well
.row-fluid
.span8.lead
!= @survey.intro
%p
%a{href: about_url}
= t('surveys.start.read_more')
= t('surveys.read_more')

= semantic_form_for [surveyor, :start, @response_set] do |f|
- question = @survey.documentation_url
Expand All @@ -56,18 +56,17 @@
= f.input :documentation_url_explanation, as: :additional_text, label: t('surveyor.override_explanation_title'), subtitle: t('surveyor.url_explanation')

.lead
:markdown
#{t('surveys.start.dataset_description')}
= t('surveys.dataset_description_html')
.span4
%button.btn.btn-large.btn-primary.submit{data:{toggle: 'popover', placement: 'bottom', content: t('surveys.start.url_problem_error')}}
%button.btn.btn-large.btn-primary.submit{data:{toggle: 'popover', placement: 'bottom', content: t('surveys.url_problem_error')}}
%i.icon-loading.icon-spin.icon-refresh
%i.icon-exclamation-sign
= t('surveys.start.check_url_button')
= t('surveys.check_url_button')

%p
= t('surveys.start.do_not_have_url')
= t('surveys.do_not_have_url')
%a.btn{href: 'take'}
= t('surveys.start.skip_this_button')
= t('surveys.skip_this_button')


/ #surveyor fieldset ol li label, #surveyor fieldset ol li input
Expand Down
1 change: 1 addition & 0 deletions config/locales/surveyor_en.yml
Original file line number Diff line number Diff line change
Expand Up @@ -35,6 +35,7 @@ en:
autocompleted_url_warning: "We have automatically completed this URL, but it doesn't seem to be correct"
metadata_missing: "Some of these items could not be found on the documentation page"
question_comment: Ask for help with this question
question_comment_read_more: Read more...
override_explanation_title: Explanation
autocomplete_explanation: Please explain the reasons why you have changed the automatically completed answer. This can help those using your data to understand it better.
url_explanation: Please explain why this URL doesn't appear to be valid. This can help those using your data to understand it better.
Expand Down
36 changes: 19 additions & 17 deletions config/locales/website_en.yml
Original file line number Diff line number Diff line change
Expand Up @@ -184,23 +184,25 @@ en:
final: Certificate in final stage

surveys:
start:
jurisdiction: 'Jurisdiction:'
language: 'Language:'
read_more: Read more about Open Data Certificates
do_not_have_url: I don't have a URL
check_url_button: Check URL
check_url_please_wait: Please wait while we check this URL
skip_this_button: Skip this
url_problem_error: There was a problem with your URL, please check, or fill out the explanation below
dataset_description: |
Link to the dataset you are certifying. By dataset we mean
the documentation or metadata that describes the data as well
as a link to the data file itself. Dataset = data + metadata.
If your data is stored in a [CKAN](http://ckan.org/) repository (such as data.gov.uk), or marked up with
[DCAT](http://www.w3.org/TR/vocab-dcat/), then we will attempt to automatically answer
some of the questions for you in the next step. [Read more...](http://theodi.org/guides/marking-up-your-dataset-with-dcat)
jurisdiction: 'Jurisdiction:'
language: 'Language:'
read_more: Read more about Open Data Certificates
do_not_have_url: I don't have a URL
check_url_button: Check URL
check_url_please_wait: Please wait while we check this URL
skip_this_button: Skip this
url_problem_error: There was a problem with your URL, please check, or fill out the explanation below
dataset_description_html: |
<p>Link to the dataset you are certifying. By dataset we mean
the documentation or metadata that describes the data as well
as a link to the data file itself. Dataset = data + metadata.</p>
<p>If your data is stored in a <a href="http://ckan.org/">CKAN</a>
repository (such as data.gov.uk), or marked up with
<a href="http://www.w3.org/TR/vocab-dcat/">DCAT</a>, then we
will attempt to automatically answer some of the questions for
you in the next step.
<a href="http://theodi.org/guides/marking-up-your-dataset-with-dcat">Read more...</a></p>
certificates:
certificates: Certificates
Expand Down

0 comments on commit 7393473

Please sign in to comment.