From: Go MAEDA Date: Sun, 2 Dec 2018 06:24:21 +0000 (+0000) Subject: Replace cancel button with cancel link in modals (#28662). X-Git-Tag: 4.0.0~26 X-Git-Url: https://source.dussan.org/?a=commitdiff_plain;h=05289f600296b8c72ae74a5397a6c14d049d5979;p=redmine.git Replace cancel button with cancel link in modals (#28662). Patch by Marius BALTEANU. git-svn-id: http://svn.redmine.org/redmine/trunk@17677 e93f8b46-1217-0410-a6f0-8f06a7374b81 --- diff --git a/app/views/groups/_new_users_modal.html.erb b/app/views/groups/_new_users_modal.html.erb index eb2e985bf..c68d3f060 100644 --- a/app/views/groups/_new_users_modal.html.erb +++ b/app/views/groups/_new_users_modal.html.erb @@ -4,6 +4,6 @@ <%= render :partial => 'new_users_form' %>

<%= submit_tag l(:button_add) %> - <%= submit_tag l(:button_cancel), :name => nil, :onclick => "hideModal(this);", :type => 'button' %> + <%= link_to_function l(:button_cancel), "hideModal(this);" %>

<% end %> diff --git a/app/views/issue_categories/_new_modal.html.erb b/app/views/issue_categories/_new_modal.html.erb index 07cc289ff..9ab1595b4 100644 --- a/app/views/issue_categories/_new_modal.html.erb +++ b/app/views/issue_categories/_new_modal.html.erb @@ -4,6 +4,6 @@ <%= render :partial => 'issue_categories/form', :locals => { :f => f } %>

<%= submit_tag l(:button_create), :name => nil %> - <%= submit_tag l(:button_cancel), :name => nil, :onclick => "hideModal(this);", :type => 'button' %> + <%= link_to_function l(:button_cancel), "hideModal(this);" %>

<% end %> diff --git a/app/views/issues/index.html.erb b/app/views/issues/index.html.erb index c02c18368..d5a77ca51 100644 --- a/app/views/issues/index.html.erb +++ b/app/views/issues/index.html.erb @@ -46,7 +46,7 @@ <% end %>

<%= submit_tag l(:button_export), :name => nil, :onclick => "hideModal(this);", :data => { :disable_with => false } %> - <%= submit_tag l(:button_cancel), :name => nil, :onclick => "hideModal(this);", :type => 'button', :data => { :disable_with => false } %> + <%= link_to_function l(:button_cancel), "hideModal(this);" %>

<% end %> diff --git a/app/views/members/_new_modal.html.erb b/app/views/members/_new_modal.html.erb index 0338a953c..3cb3360f5 100644 --- a/app/views/members/_new_modal.html.erb +++ b/app/views/members/_new_modal.html.erb @@ -4,6 +4,6 @@ <%= render :partial => 'new_form' %>

<%= submit_tag l(:button_add), :id => 'member-add-submit' %> - <%= submit_tag l(:button_cancel), :name => nil, :onclick => "hideModal(this);", :type => 'button' %> + <%= link_to_function l(:button_cancel), "hideModal(this);" %>

<% end %> diff --git a/app/views/principal_memberships/_new_modal.html.erb b/app/views/principal_memberships/_new_modal.html.erb index 175e09330..945eff73c 100644 --- a/app/views/principal_memberships/_new_modal.html.erb +++ b/app/views/principal_memberships/_new_modal.html.erb @@ -4,6 +4,6 @@ <%= render :partial => 'new_form' %>

<%= submit_tag l(:button_add), :name => nil %> - <%= submit_tag l(:button_cancel), :name => nil, :onclick => "hideModal(this);", :type => 'button' %> + <%= link_to_function l(:button_cancel), "hideModal(this);" %>

<% end %> diff --git a/app/views/sudo_mode/_new_modal.html.erb b/app/views/sudo_mode/_new_modal.html.erb index adc4851cc..bc780be56 100644 --- a/app/views/sudo_mode/_new_modal.html.erb +++ b/app/views/sudo_mode/_new_modal.html.erb @@ -13,6 +13,6 @@

<%= submit_tag l(:button_submit), onclick: "hideModal(this);" %> - <%= submit_tag l(:button_cancel), name: nil, onclick: "hideModal(this);", type: 'button' %> + <%= link_to_function l(:button_cancel), "hideModal(this);" %>

<% end %> diff --git a/app/views/timelog/index.html.erb b/app/views/timelog/index.html.erb index 9f320d637..35e833efb 100644 --- a/app/views/timelog/index.html.erb +++ b/app/views/timelog/index.html.erb @@ -34,7 +34,7 @@ <%= export_csv_encoding_select_tag %>

<%= submit_tag l(:button_export), :name => nil, :onclick => "hideModal(this);", :data => { :disable_with => false } %> - <%= submit_tag l(:button_cancel), :name => nil, :onclick => "hideModal(this);", :type => 'button', :data => { :disable_with => false } %> + <%= link_to_function l(:button_cancel), "hideModal(this);" %>

<% end %> diff --git a/app/views/versions/_new_modal.html.erb b/app/views/versions/_new_modal.html.erb index 99fef84e5..052a73974 100644 --- a/app/views/versions/_new_modal.html.erb +++ b/app/views/versions/_new_modal.html.erb @@ -4,6 +4,6 @@ <%= render :partial => 'versions/form', :locals => { :f => f } %>

<%= submit_tag l(:button_create), :name => nil %> - <%= submit_tag l(:button_cancel), :name => nil, :onclick => "hideModal(this);", :type => 'button' %> + <%= link_to_function l(:button_cancel), "hideModal(this);" %>

<% end %> diff --git a/app/views/watchers/_new.html.erb b/app/views/watchers/_new.html.erb index 3640c6993..3bd7953ac 100644 --- a/app/views/watchers/_new.html.erb +++ b/app/views/watchers/_new.html.erb @@ -26,6 +26,6 @@

<%= submit_tag l(:button_add), :name => nil, :onclick => "hideModal(this);" %> - <%= submit_tag l(:button_cancel), :name => nil, :onclick => "hideModal(this);", :type => 'button' %> + <%= link_to_function l(:button_cancel), "hideModal(this);" %>

<% end %> diff --git a/app/views/wiki/_new_modal.html.erb b/app/views/wiki/_new_modal.html.erb index 2f9dcdb7f..108c6ad88 100644 --- a/app/views/wiki/_new_modal.html.erb +++ b/app/views/wiki/_new_modal.html.erb @@ -24,6 +24,6 @@

<%= submit_tag l(:label_next), :name => nil %> - <%= submit_tag l(:button_cancel), :name => nil, :onclick => "hideModal(this);", :type => 'button' %> + <%= link_to_function l(:button_cancel), "hideModal(this);" %>

<% end %>