diff options
author | Fabrice Bellingard <bellingard@gmail.com> | 2011-09-19 14:39:41 +0200 |
---|---|---|
committer | Fabrice Bellingard <bellingard@gmail.com> | 2011-09-19 14:39:41 +0200 |
commit | 0ce576e728ed719f2b89bace3eac6b711209f704 (patch) | |
tree | 39bcf65c403045c9d0fb832cebab42d858e915f2 | |
parent | 038f9a0b69d405235238565f35e4525c966b0712 (diff) | |
download | sonarqube-0ce576e728ed719f2b89bace3eac6b711209f704.tar.gz sonarqube-0ce576e728ed719f2b89bace3eac6b711209f704.zip |
SONAR-893 Fix bug of update request on Derby
-rw-r--r-- | sonar-server/src/main/webapp/WEB-INF/app/controllers/project_controller.rb | 2 | ||||
-rw-r--r-- | sonar-server/src/main/webapp/WEB-INF/app/views/project/history.html.erb | 2 |
2 files changed, 2 insertions, 2 deletions
diff --git a/sonar-server/src/main/webapp/WEB-INF/app/controllers/project_controller.rb b/sonar-server/src/main/webapp/WEB-INF/app/controllers/project_controller.rb index 3e4c077a09c..c9097ef560d 100644 --- a/sonar-server/src/main/webapp/WEB-INF/app/controllers/project_controller.rb +++ b/sonar-server/src/main/webapp/WEB-INF/app/controllers/project_controller.rb @@ -66,7 +66,7 @@ class ProjectController < ApplicationController sid = params[:snapshot_id] if sid - Snapshot.update_all("status='U'", ["id=? or root_snapshot_id=(?)", sid, sid]) + Snapshot.update_all("status='U'", ["id=? or root_snapshot_id=(?)", sid.to_i, sid.to_i]) flash[:notice] = message('project_history.snapshot_deleted') end diff --git a/sonar-server/src/main/webapp/WEB-INF/app/views/project/history.html.erb b/sonar-server/src/main/webapp/WEB-INF/app/views/project/history.html.erb index 4c8dc6235b1..c0be0cb0b8d 100644 --- a/sonar-server/src/main/webapp/WEB-INF/app/views/project/history.html.erb +++ b/sonar-server/src/main/webapp/WEB-INF/app/views/project/history.html.erb @@ -34,7 +34,7 @@ cell_content = "<b>" + message('project_history.last_snapshot') + "</b>" else cell_content = button_to( message('project_history.delete_snapshot'), - { :action => "delete_snapshot_history", :id => @project.id, :snapshot_id => [snapshot.id] }, + { :action => "delete_snapshot_history", :id => @project.id, :snapshot_id => snapshot.id }, :class => 'action red-button', :confirm => message('project_history.are_you_sure_delete_snapshot_x', :params => l(time, :format => :long)) ) end |