aboutsummaryrefslogtreecommitdiffstats
path: root/sonar-server
diff options
context:
space:
mode:
authorJulien Lancelot <julien.lancelot@gmail.com>2013-08-13 12:28:50 +0200
committerJulien Lancelot <julien.lancelot@gmail.com>2013-08-13 12:28:50 +0200
commit1b78d73edf02520d98d15be6970f5695aa3cd8ca (patch)
tree5a7c2652563f393b06d396f0fbddfa94a8c9f2c9 /sonar-server
parent46b8d93f95920588e0a6d8c1befd3dc2a988def4 (diff)
downloadsonarqube-1b78d73edf02520d98d15be6970f5695aa3cd8ca.tar.gz
sonarqube-1b78d73edf02520d98d15be6970f5695aa3cd8ca.zip
SONAR-4573 Remove the hack which leads do display the 'Project Permissions' page on views even if the property 'hasRolePolicy' is not defined on views
Diffstat (limited to 'sonar-server')
-rw-r--r--sonar-server/src/main/webapp/WEB-INF/app/views/layouts/_menu_resource_settings.html.erb5
-rw-r--r--sonar-server/src/main/webapp/WEB-INF/lib/resourceable.rb2
2 files changed, 3 insertions, 4 deletions
diff --git a/sonar-server/src/main/webapp/WEB-INF/app/views/layouts/_menu_resource_settings.html.erb b/sonar-server/src/main/webapp/WEB-INF/app/views/layouts/_menu_resource_settings.html.erb
index d6362174d1b..fde05bbc14d 100644
--- a/sonar-server/src/main/webapp/WEB-INF/app/views/layouts/_menu_resource_settings.html.erb
+++ b/sonar-server/src/main/webapp/WEB-INF/app/views/layouts/_menu_resource_settings.html.erb
@@ -19,10 +19,7 @@
<% if (is_admin && @project.project?) %>
<li><a href="<%= ApplicationController.root_context -%>/project/links/<%= @project.id -%>"><%= message('project_links.page') -%></a></li>
<% end %>
- <%
- # NOTE: we keep "@project.view?" in the test for backward compatibility with the Views plugin
- if (is_admin && controller.java_facade.getResourceTypeBooleanProperty(@project.qualifier, 'hasRolePolicy') || @project.view?)
- %>
+ <% if is_admin && controller.java_facade.getResourceTypeBooleanProperty(@project.qualifier, 'hasRolePolicy') %>
<li><a href="<%= ApplicationController.root_context -%>/project_roles/index/<%= @project.id -%>"><%= message('roles.page') -%></a></li>
<% end %>
<% if is_admin && controller.java_facade.getResourceTypeBooleanProperty(@project.qualifier, 'modifiable_history') %>
diff --git a/sonar-server/src/main/webapp/WEB-INF/lib/resourceable.rb b/sonar-server/src/main/webapp/WEB-INF/lib/resourceable.rb
index edb4a03277d..32513ba6695 100644
--- a/sonar-server/src/main/webapp/WEB-INF/lib/resourceable.rb
+++ b/sonar-server/src/main/webapp/WEB-INF/lib/resourceable.rb
@@ -53,10 +53,12 @@ module Resourceable
qualifier==QUALIFIER_LIB
end
+ # No more used since SonarQube 4.0 and should not be used anymore
def view?
qualifier==QUALIFIER_VIEW
end
+ # No more used and should not be used
def subview?
qualifier==QUALIFIER_SUBVIEW
end