From c3a1ff31b2f9e02eccd78338ed101154b7c5ac78 Mon Sep 17 00:00:00 2001 From: Fabrice Bellingard Date: Fri, 29 Apr 2011 16:33:51 +0200 Subject: [PATCH] SONAR-2327 Fix a problem on the permalink page --- .../webapp/WEB-INF/app/controllers/reviews_controller.rb | 2 +- .../main/webapp/WEB-INF/app/views/reviews/_show.html.erb | 8 +++++++- .../main/webapp/WEB-INF/app/views/reviews/_view.html.erb | 3 +++ 3 files changed, 11 insertions(+), 2 deletions(-) create mode 100644 sonar-server/src/main/webapp/WEB-INF/app/views/reviews/_view.html.erb diff --git a/sonar-server/src/main/webapp/WEB-INF/app/controllers/reviews_controller.rb b/sonar-server/src/main/webapp/WEB-INF/app/controllers/reviews_controller.rb index f94e9ad4685..ceae2e09cf7 100644 --- a/sonar-server/src/main/webapp/WEB-INF/app/controllers/reviews_controller.rb +++ b/sonar-server/src/main/webapp/WEB-INF/app/controllers/reviews_controller.rb @@ -37,7 +37,7 @@ class ReviewsController < ApplicationController def view @review = Review.find(params[:id], :include => ['project']) if current_user && has_role?(:user, @review.project) - render 'reviews/_review', :locals => {:review => @review} + render 'reviews/_view', :locals => {:review => @review} else render :text => "Cannot access this review : access denied." end diff --git a/sonar-server/src/main/webapp/WEB-INF/app/views/reviews/_show.html.erb b/sonar-server/src/main/webapp/WEB-INF/app/views/reviews/_show.html.erb index 7e90b13accb..b9faf2e6d30 100644 --- a/sonar-server/src/main/webapp/WEB-INF/app/views/reviews/_show.html.erb +++ b/sonar-server/src/main/webapp/WEB-INF/app/views/reviews/_show.html.erb @@ -1,5 +1,11 @@ -
+ + <%= render :partial => 'reviews/review', :locals => {:review => @review} -%> \ No newline at end of file diff --git a/sonar-server/src/main/webapp/WEB-INF/app/views/reviews/_view.html.erb b/sonar-server/src/main/webapp/WEB-INF/app/views/reviews/_view.html.erb new file mode 100644 index 00000000000..3a8dd3568a7 --- /dev/null +++ b/sonar-server/src/main/webapp/WEB-INF/app/views/reviews/_view.html.erb @@ -0,0 +1,3 @@ +
+ <%= render :partial => 'reviews/review' -%> +
-- 2.39.5