From: Andy Allan Date: Wed, 12 Jun 2019 14:32:52 +0000 (+0200) Subject: Use built-in form submit translation keys for oauth client applications X-Git-Tag: live~2562^2~1 X-Git-Url: https://git.openstreetmap.org/rails.git/commitdiff_plain/1d09cfcb18d589ea494bf5223f2eb9e0a773d7c6?hp=085412f6240cf675b3d8fecbace22edf577962b3 Use built-in form submit translation keys for oauth client applications --- diff --git a/app/views/oauth_clients/edit.html.erb b/app/views/oauth_clients/edit.html.erb index d6211778b..d696baae3 100644 --- a/app/views/oauth_clients/edit.html.erb +++ b/app/views/oauth_clients/edit.html.erb @@ -4,5 +4,5 @@ <%= form_for @client_application, :url => oauth_client_path(@client_application.user.display_name, @client_application), :html => { :method => :put } do |f| %> <%= render :partial => "form", :locals => { :f => f } %> - <%= submit_tag t ".submit" %> + <%= f.submit %> <% end %> diff --git a/app/views/oauth_clients/new.html.erb b/app/views/oauth_clients/new.html.erb index 0a49f48f8..d9cc05d02 100644 --- a/app/views/oauth_clients/new.html.erb +++ b/app/views/oauth_clients/new.html.erb @@ -3,8 +3,8 @@ <% end %>
- <%= form_for :client_application, :url => { :action => :create } do |f| %> + <%= form_for @client_application, :url => { :action => :create } do |f| %> <%= render :partial => "form", :locals => { :f => f } %> - <%= submit_tag t(".submit") %> + <%= f.submit %> <% end %>
diff --git a/config/locales/en.yml b/config/locales/en.yml index 71abe1efe..c835df967 100644 --- a/config/locales/en.yml +++ b/config/locales/en.yml @@ -16,6 +16,9 @@ en: create: Add Comment message: create: Send + client_application: + create: Register + update: Edit redaction: create: Create redaction update: Save redaction @@ -1891,10 +1894,8 @@ en: oauth_clients: new: title: "Register a new application" - submit: "Register" edit: title: "Edit your application" - submit: "Edit" show: title: "OAuth details for %{app_name}" key: "Consumer Key:"