diff --git a/app/assets/javascripts/admin.js b/app/assets/javascripts/admin.js index e1e0f97..0b5dcdd 100644 --- a/app/assets/javascripts/admin.js +++ b/app/assets/javascripts/admin.js @@ -234,7 +234,7 @@ $('.new_question_save_button').click(function(e){ var s_id = $(this).prev(".section_id").val(); if ($('#new_question_text_'+ s_id).val() == ''){ - alert(I18n.t("question_text_empty")); + alert(I18n.t("js.question_text_empty")); return false; } }); @@ -327,24 +327,24 @@ //verify if text area is not nil var editorContent = tinyMCE.get('guidance-text').getContent(); if (editorContent == ''){ - alert_message.push(I18n.t("add_guidance_text")); + alert_message.push(I18n.t("js.add_guidance_text")); } //verify dropdown with questions has a selected option if guidance for a question being used if ($('#g_options').val() == '2') { if ($('#questions_select').val() == '' || isNaN($('#questions_select').val())){ - alert_message.push(I18n.t("select_question")); + alert_message.push(I18n.t("js.select_question")); } } //verify dropdown with questions has a selected option if guidance for a question being used if ($('#g_options').val() == '1' ){ if($('#guidance_theme_ids').val() == undefined || $('#guidance_theme_ids').val() == ''){ - alert_message.push(I18n.t("select_at_least_one_theme")); + alert_message.push(I18n.t("js.select_at_least_one_theme")); } } //verify if guidance group is selected if ( ($('#guidance_guidance_group_ids').val() == '') || $('#guidance_guidance_group_ids').val() == undefined ) { - alert_message.push(I18n.t("select_guidance_group")); + alert_message.push(I18n.t("js.select_guidance_group")); } if(alert_message.length == 0){ //clear dropdowns before submission @@ -389,23 +389,23 @@ //verify if text area is not nil var editorContent = tinyMCE.get('guidance-text').getContent(); if (editorContent == ''){ - alert_message.push(I18n.t("add_guidance_text")); + alert_message.push(I18n.t("js.add_guidance_text")); } //verify dropdown with questions has a selected option if guidance for a question being used if ($('#g_options').val() == '2') { if ($('#questions_select').val() == '' || isNaN($('#questions_select').val())){ - alert_message.push(I18n.t("select_question")); + alert_message.push(I18n.t("js.select_question")); } } //verify dropdown with questions has a selected option if guidance for a question being used if ($('#g_options').val() == '1' ){ if($('#guidance_theme_ids').val() == undefined || $('#guidance_theme_ids').val() == ''){ - alert_message.push(I18n.t("select_at_least_one_theme")); + alert_message.push(I18n.t("js.select_at_least_one_theme")); } } //verify if guidance group is selected if ( ($('#guidance_guidance_group_ids').val() == '') || $('#guidance_guidance_group_ids').val() == undefined ) { - alert_message.push(I18n.t("select_guidance_group")); + alert_message.push(I18n.t("js.select_guidance_group")); } if(alert_message.length == 0){ @@ -437,7 +437,7 @@ //Validate banner_text area for less than 165 character $("form#edit_org_details").submit(function(){ if (getStats('org_banner_text').chars > 165) { - alert(I18n.t("enter_up_to") + " " + getStats('org_banner_text').chars + ". " + I18n.t("if_using_url_try")); + alert(I18n.t("js.enter_up_to") + " " + getStats('org_banner_text').chars + ". " + I18n.t("js.if_using_url_try")); return false; } }); diff --git a/app/views/devise/confirmations/new.html.erb b/app/views/devise/confirmations/new.html.erb index bfb06f6..d5cc21d 100644 --- a/app/views/devise/confirmations/new.html.erb +++ b/app/views/devise/confirmations/new.html.erb @@ -1,4 +1,4 @@ -
<% t('custom_devise.welcome_to_DMP') %>, <%= @email %>!
+<%= t('custom_devise.welcome_to_DMP') %>, <%= @email %>!
-<% t('custom_devise.thank_you_and_confirm') %>
+<%= t('custom_devise.thank_you_and_confirm') %>
-<%= link_to t('custom_devise.click_to_confirm'), confirmation_url(@resource, :confirmation_token => @token) %> <% t('custom_devise.1st_part_copy') %> <%= confirmation_url(@resource, :confirmation_token => @token) %> <% t('custom_devise.2nd_part_copy') %>
\ No newline at end of file +<%= link_to t('custom_devise.click_to_confirm'), confirmation_url(@resource, :confirmation_token => @token) %> <%= t('custom_devise.1st_part_copy') %> <%= confirmation_url(@resource, :confirmation_token => @token) %> <%= t('custom_devise.2nd_part_copy') %>
\ No newline at end of file diff --git a/app/views/devise/mailer/invitation_instructions.html.erb b/app/views/devise/mailer/invitation_instructions.html.erb index 1215d1b..2828329 100644 --- a/app/views/devise/mailer/invitation_instructions.html.erb +++ b/app/views/devise/mailer/invitation_instructions.html.erb @@ -1,7 +1,7 @@ -<% t('custom_devise.hello') %> <%= @resource.email %>!
+<%= t('custom_devise.hello') %> <%= @resource.email %>!
-<% t('custom_devise.colleague_invited_you') %> <%= link_to t('tool_title'), root_url %>
+<%= t('custom_devise.colleague_invited_you') %> <%= link_to t('tool_title'), root_url %>
-<%= link_to t('custom_devise.click_to_accept'), accept_invitation_url(@resource, :invitation_token => @token) %> <% t('custom_devise.1st_part_copy') %> <%= accept_invitation_url(@resource, :invitation_token => @token) %> <% t('custom_devise.2nd_part_copy') %>
+<%= link_to t('custom_devise.click_to_accept'), accept_invitation_url(@resource, :invitation_token => @token) %> <%= t('custom_devise.1st_part_copy') %> <%= accept_invitation_url(@resource, :invitation_token => @token) %> <%= t('custom_devise.2nd_part_copy') %>
-<% t('custom_devise.ignore_wont_be_created') %> \ No newline at end of file +<%= t('custom_devise.ignore_wont_be_created') %> \ No newline at end of file diff --git a/app/views/devise/mailer/reset_password_instructions.html.erb b/app/views/devise/mailer/reset_password_instructions.html.erb index 23df47b..1638d2e 100644 --- a/app/views/devise/mailer/reset_password_instructions.html.erb +++ b/app/views/devise/mailer/reset_password_instructions.html.erb @@ -1,7 +1,7 @@ -<% t('custom_devise.hello') %> <%= @resource.email %>!
+<%= t('custom_devise.hello') %> <%= @resource.email %>!
-<% t('custom_devise.1st_part_change_password') %> <%= link_to t('tool_title'), root_url %> <% t('custom_devise.2nd_part_change_password') %>
+<%= t('custom_devise.1st_part_change_password') %> <%= link_to t('tool_title'), root_url %> <%= t('custom_devise.2nd_part_change_password') %>
<%= link_to 'Change my password', edit_password_url(@resource, :reset_password_token => @token) %>
-<% t('custom_devise.1st_part_change_password') %> +<%= t('custom_devise.1st_part_change_password') %> diff --git a/app/views/devise/mailer/unlock_instructions.html.erb b/app/views/devise/mailer/unlock_instructions.html.erb index 8730474..955c0c7 100644 --- a/app/views/devise/mailer/unlock_instructions.html.erb +++ b/app/views/devise/mailer/unlock_instructions.html.erb @@ -1,7 +1,7 @@ -<% t('custom_devise.hello') %> <%= @resource.email %>!
+<%= t('custom_devise.hello') %> <%= @resource.email %>!
-<% t('custom_devise.1st_part_locked') %><%= link_to t('tool_title'), root_url %><% t('custom_devise.2nd_part_locked') %>
+<%= t('custom_devise.1st_part_locked') %><%= link_to t('tool_title'), root_url %><%= t('custom_devise.2nd_part_locked') %>
-<% t('custom_devise.click_to_unlock') %>
+<%= t('custom_devise.click_to_unlock') %>
<%= link_to t('custom_devise.unlock'), unlock_url(@resource, :unlock_token => @token) %>
\ No newline at end of file diff --git a/app/views/devise/registrations/edit.html.erb b/app/views/devise/registrations/edit.html.erb index fb692c8..dffb99f 100644 --- a/app/views/devise/registrations/edit.html.erb +++ b/app/views/devise/registrations/edit.html.erb @@ -80,7 +80,7 @@| <%= t("helpers.current_password") %> | diff --git a/app/views/devise/unlocks/new.html.erb b/app/views/devise/unlocks/new.html.erb index d7c8019..b632e4f 100644 --- a/app/views/devise/unlocks/new.html.erb +++ b/app/views/devise/unlocks/new.html.erb @@ -1,4 +1,4 @@ -