diff --git a/app/views/guidances/_edit_guidance.html.erb b/app/views/guidances/_edit_guidance.html.erb index a66df3a..36fe926 100644 --- a/app/views/guidances/_edit_guidance.html.erb +++ b/app/views/guidances/_edit_guidance.html.erb @@ -19,7 +19,7 @@
<%= f.submit _('Save'), class: "btn btn-primary" %> <%= link_to _('Delete'), admin_destroy_suggested_answer_path(id: suggested_answer.id), - confirm: _('You are about to delete a suggested answer/ example for '%{question_text}'. Are you sure?') % { question_text: => question.text }, method: :delete, class: "btn btn-primary"%> + confirm: _("You are about to delete a suggested answer/ example for '%{question_text}'. Are you sure?") % { :question_text => question.text }, method: :delete, class: "btn btn-primary"%> <%= hidden_field_tag :question_id, question.id, class: "question_id" %> <%= link_to _('Cancel'), "#", class: "btn cancel cancel_edit_suggested_answer" %>
diff --git a/app/views/guidances/admin_index.html.erb b/app/views/guidances/admin_index.html.erb index fd40d01..406b45f 100644 --- a/app/views/guidances/admin_index.html.erb +++ b/app/views/guidances/admin_index.html.erb @@ -54,7 +54,7 @@ <%= link_to _('View'), admin_show_guidance_group_path(guidance_gr), class: "dmp_table_link"%>
<%= link_to _('Edit'), admin_edit_guidance_group_path(guidance_gr), class: "dmp_table_link"%>
- <%= link_to _('Delete'), admin_destroy_guidance_group_path(guidance_gr), data: {confirm: _("You are about to delete '%{guidance_group_name}'. This will affect guidance. Are you sure?") % {guidance_group_name: => guidance_gr.name }}, method: :delete, class: "dmp_table_link"%> + <%= link_to _('Delete'), admin_destroy_guidance_group_path(guidance_gr), data: {confirm: _("You are about to delete '%{guidance_group_name}'. This will affect guidance. Are you sure?") % { :guidance_group_name => guidance_gr.name }}, method: :delete, class: "dmp_table_link"%> <% end %> @@ -139,7 +139,7 @@ <%= link_to _('View'), admin_show_guidance_path(guidance), class: "dmp_table_link"%>
<%= link_to _('Edit'), admin_edit_guidance_path(guidance), class: "dmp_table_link"%>
<%= link_to _('Delete'), admin_destroy_guidance_path(guidance), - data: {confirm: _('You are about to delete '%{guidance_summary}'. Are you sure?') % { guidance_summary: => truncate(sanitize(guidance.text,tags: %w(br a)), length: 20 , omission: _('... (continued)'))} }, method: :delete, class: "dmp_table_link"%> + data: {confirm: _("You are about to delete '%{guidance_summary}'. Are you sure?") % { :guidance_summary => truncate(sanitize(guidance.text,tags: %w(br a)), length: 20 , omission: _('... (continued)'))} }, method: :delete, class: "dmp_table_link"%> <% end %> diff --git a/app/views/questions/_edit_question.html.erb b/app/views/questions/_edit_question.html.erb index 338465c..d416548 100644 --- a/app/views/questions/_edit_question.html.erb +++ b/app/views/questions/_edit_question.html.erb @@ -161,7 +161,7 @@ <%= f.submit _('Save'), class: "btn btn-primary" %> <% if !question.section.phase.template.published? %> <%= link_to _('Delete'), admin_destroy_question_path(question_id: question.id), - confirm: _('You are about to delete '%{question_text}'. Are you sure?') % { question_text: => question.text }, method: :delete, class: "btn btn-primary"%> + confirm: _("You are about to delete '%{question_text}'. Are you sure?") % { :question_text => question.text }, method: :delete, class: "btn btn-primary"%> <% end %> <%= hidden_field_tag :question_id, question.id, class: "question_id" %> <%= link_to _('Cancel'), "#", class: "btn cancel cancel_edit_question" %> diff --git a/app/views/questions/_show_question.html.erb b/app/views/questions/_show_question.html.erb index 1a0ce91..335c91e 100644 --- a/app/views/questions/_show_question.html.erb +++ b/app/views/questions/_show_question.html.erb @@ -126,7 +126,7 @@ <%= link_to _('Edit question'), '# ', class: "btn btn-primary edit_question_button"%> <% if !question.section.published? %> <%= link_to _('Delete question'), admin_destroy_question_path(question_id: question.id), - confirm: _('You are about to delete '%{question_text}'. Are you sure?') % { :question_text => question.text }, method: :delete, class: "btn btn-primary"%> + confirm: _("You are about to delete '%{question_text}'. Are you sure?") % { :question_text => question.text }, method: :delete, class: "btn btn-primary"%> <% end %> <% elsif !@edit && question.modifiable %> diff --git a/app/views/sections/_edit_section.html.erb b/app/views/sections/_edit_section.html.erb index 283ce04..59d8865 100644 --- a/app/views/sections/_edit_section.html.erb +++ b/app/views/sections/_edit_section.html.erb @@ -58,7 +58,7 @@ <%= s.submit _('Save'), class: 'btn btn-primary' %> <% if section.modifiable %> <%= link_to _('Delete'), admin_destroy_section_path(section_id: section.id), - confirm: _('You are about to delete '%{section_title}'. This will affect questions linked to this section. Are you sure?') % { section_title: => section.title }, method: :delete, class: "btn btn-primary"%> + confirm: _("You are about to delete '%{section_title}'. This will affect questions linked to this section. Are you sure?") % { :section_title => section.title }, method: :delete, class: "btn btn-primary"%> <% end %> <%= link_to _('Cancel'), :back, class: 'btn cancel' %> diff --git a/app/views/suggested_answers/_edit_suggested_answer.html.erb b/app/views/suggested_answers/_edit_suggested_answer.html.erb index 694e4b4..f0d92b7 100644 --- a/app/views/suggested_answers/_edit_suggested_answer.html.erb +++ b/app/views/suggested_answers/_edit_suggested_answer.html.erb @@ -19,7 +19,7 @@
<%= f.submit _('Save'), class: 'btn btn-primary' %> <%= link_to _('Delete'), admin_destroy_suggested_answer_path(id: suggested_answer.id), - confirm: _('You are about to delete a suggested answer/ example for '%{question_text}'. Are you sure?') % { :question_text => question.text }, method: :delete, class: "btn btn-primary"%> + confirm: _("You are about to delete a suggested answer/ example for '%{question_text}'. Are you sure?") % { :question_text => question.text }, method: :delete, class: "btn btn-primary"%> <%= hidden_field_tag :question_id, question.id, class: "question_id" %> <%= link_to _('Cancel'), '#', class: 'btn cancel cancel_edit_suggested_answer' %>
diff --git a/app/views/templates/_edit_annotations.html.erb b/app/views/templates/_edit_annotations.html.erb index 6f7b3c7..020ce5c 100644 --- a/app/views/templates/_edit_annotations.html.erb +++ b/app/views/templates/_edit_annotations.html.erb @@ -89,7 +89,7 @@ <%= f.submit _('Save'), class: "btn btn-primary" %> <% if !question.section.phase.template.published? %> <%= link_to _('Delete'), admin_destroy_question_path(question_id: question.id), - confirm: _("You are about to delete '%{question_text}'. Are you sure?") % { question_text: => question.text }, method: :delete, class: "btn btn-primary"%> + confirm: _("You are about to delete '%{question_text}'. Are you sure?") % { :question_text => question.text }, method: :delete, class: "btn btn-primary"%> <% end %> <%= hidden_field_tag :question_id, question.id, class: "question_id" %> <%= link_to _('Cancel'), "#", class: "btn cancel cancel_edit_question" %> diff --git a/app/views/templates/_show_phases_sections.html.erb b/app/views/templates/_show_phases_sections.html.erb index ec0a5df..e802f08 100644 --- a/app/views/templates/_show_phases_sections.html.erb +++ b/app/views/templates/_show_phases_sections.html.erb @@ -16,7 +16,7 @@ <% end %> <% if !phase.template.published? %> <%= link_to _('Delete'), admin_destroy_phase_path(phase_id: phase.id), - confirm: _('You are about to delete '%{phase_title}'. This will affect versions, sections and questions linked to this phase. Are you sure?') % { :phase_title => phase.title }, method: :delete, class: "btn btn-primary"%> + confirm: _("You are about to delete '%{phase_title}'. This will affect versions, sections and questions linked to this phase. Are you sure?") % { :phase_title => phase.title }, method: :delete, class: "btn btn-primary"%> <% end %> <% if !phase.modifiable %> <% b_label = _('View phase')%>