From: Ævar Arnfjörð Bjarmason Date: Thu, 1 Oct 2009 18:02:08 +0000 (+0000) Subject: Set title/h1 to something sensible when granting/revoking roles X-Git-Tag: live~6620^2~26 X-Git-Url: https://git.openstreetmap.org/rails.git/commitdiff_plain/8a7040e155cb2f56661d6695422e6ccac88a7bdd Set title/h1 to something sensible when granting/revoking roles --- diff --git a/app/views/user_roles/grant.html.erb b/app/views/user_roles/grant.html.erb index ca45266d6..f9e54fd1c 100644 --- a/app/views/user_roles/grant.html.erb +++ b/app/views/user_roles/grant.html.erb @@ -1,5 +1,7 @@ <% form_tag request.request_uri do %> <%= hidden_field_tag 'nonce', @nonce %> +<% @title = t('user_role.grant.heading') %> +

<%= t('user_role.grant.heading') %>

<%= t('user_role.grant.are_you_sure', :name => params[:display_name], :role => params[:role]) %>

<%= submit_tag t'user_role.grant.confirm' %>

<% end %> diff --git a/app/views/user_roles/revoke.html.erb b/app/views/user_roles/revoke.html.erb index 17219d9c7..e5aadeae0 100644 --- a/app/views/user_roles/revoke.html.erb +++ b/app/views/user_roles/revoke.html.erb @@ -1,5 +1,7 @@ <% form_tag request.request_uri do %> <%= hidden_field_tag 'nonce', @nonce %> +<% @title = t('user_role.revoke.heading') %> +

<%= t('user_role.revoke.heading') %>

<%= t('user_role.revoke.are_you_sure', :name => params[:display_name], :role => params[:role]) %>

<%= submit_tag t'user_role.revoke.confirm' %>

<% end %> diff --git a/config/locales/en.yml b/config/locales/en.yml index 8d53dcdf3..9105a2d42 100644 --- a/config/locales/en.yml +++ b/config/locales/en.yml @@ -1013,10 +1013,14 @@ en: already_has_role: "The user already has role {{role}}." doesnt_have_role: "The user does not have role {{role}}." grant: + title: Confirm role granting + heading: Confirm role granting are_you_sure: "Are you sure you want to grant the role `{{role}}' to the user `{{name}}'?" confirm: "Confirm" fail: "Couldn't grant role `{{role}}' to user `{{name}}'. Please check that the user and role are both valid." revoke: + title: Confirm role revoking + heading: Confirm role revoking are_you_sure: "Are you sure you want to revoke the role `{{role}}' from the user `{{name}}'?" confirm: "Confirm" fail: "Couldn't revoke role `{{role}}' from user `{{name}}'. Please check that the user and role are both valid."