diff options
author | Fabrice Bellingard <bellingard@gmail.com> | 2011-06-22 12:41:39 +0200 |
---|---|---|
committer | Fabrice Bellingard <bellingard@gmail.com> | 2011-06-22 12:41:39 +0200 |
commit | 3ef8dc991ef66336d4730f8f7766d0f34363d8a8 (patch) | |
tree | 456c7985c5f62486f304b52dd69bd50de8df2d31 | |
parent | 5b627f797640455ed3fc4a6a075d278ed5dd9372 (diff) | |
download | sonarqube-3ef8dc991ef66336d4730f8f7766d0f34363d8a8.tar.gz sonarqube-3ef8dc991ef66336d4730f8f7766d0f34363d8a8.zip |
SONAR-2436 Fix problem with delete button on filters
-rw-r--r-- | sonar-server/src/main/webapp/WEB-INF/app/views/filters/new.html.erb | 3 |
1 files changed, 2 insertions, 1 deletions
diff --git a/sonar-server/src/main/webapp/WEB-INF/app/views/filters/new.html.erb b/sonar-server/src/main/webapp/WEB-INF/app/views/filters/new.html.erb index 6475a4d1ed6..5428a8aeb1e 100644 --- a/sonar-server/src/main/webapp/WEB-INF/app/views/filters/new.html.erb +++ b/sonar-server/src/main/webapp/WEB-INF/app/views/filters/new.html.erb @@ -163,7 +163,8 @@ table#columns td { <input type="submit" value="Save & Close" /> <span class="spacer"> </span> <% if @filter.id %> - <input name="delete" class="red-button" type="submit" value="Delete" onclick="return confirm('Do you want to delete this filter ?');"> + <input name="delete" class="red-button" value="Delete" type="button" + onclick="if (confirm('Do you want to delete this filter ?')) { var f = document.createElement('form'); f.style.display = 'none'; this.parentNode.appendChild(f); f.method = 'POST'; f.action = '<%= url_for :action => 'delete', :id => @filter.id %>';f.submit(); };return false;"> <span class="spacer"> </span> <a href="<%= url_for :action => 'index', :name => @filter.name -%>">Cancel</a> <% else %> |