From 0c585e0f026f659792939b4c5b82aa506b5a7cba Mon Sep 17 00:00:00 2001 From: simonbrandhof Date: Wed, 22 Dec 2010 15:07:00 +0000 Subject: [PATCH] SONAR-1722 rename the Inheritance Tree tab + add missing image --- .../app/controllers/profiles_controller.rb | 8 ++++---- .../WEB-INF/app/views/profiles/_tabs.html.erb | 2 +- .../{hierarchy.html.erb => inheritance.html.erb} | 6 +++--- .../src/main/webapp/images/up-blue-24.png | Bin 0 -> 928 bytes 4 files changed, 8 insertions(+), 8 deletions(-) rename sonar-server/src/main/webapp/WEB-INF/app/views/profiles/{hierarchy.html.erb => inheritance.html.erb} (81%) create mode 100644 sonar-server/src/main/webapp/images/up-blue-24.png diff --git a/sonar-server/src/main/webapp/WEB-INF/app/controllers/profiles_controller.rb b/sonar-server/src/main/webapp/WEB-INF/app/controllers/profiles_controller.rb index ea222e8aa56..fcd05e004fd 100644 --- a/sonar-server/src/main/webapp/WEB-INF/app/controllers/profiles_controller.rb +++ b/sonar-server/src/main/webapp/WEB-INF/app/controllers/profiles_controller.rb @@ -24,7 +24,7 @@ class ProfilesController < ApplicationController verify :method => :post, :only => ['create', 'delete', 'copy', 'set_as_default', 'restore', 'set_projects', 'rename', 'change_parent'], :redirect_to => { :action => 'index' } # the backup action is allow to non-admin users : see http://jira.codehaus.org/browse/SONAR-2039 - before_filter :admin_required, :except => [ 'index', 'show', 'projects', 'permalinks', 'export', 'backup', 'hierarchy' ] + before_filter :admin_required, :except => [ 'index', 'show', 'projects', 'permalinks', 'export', 'backup', 'inheritance' ] # # @@ -187,10 +187,10 @@ class ProfilesController < ApplicationController # # - # GET /profiles/hierarchy?id= + # GET /profiles/inheritance?id= # # - def hierarchy + def inheritance @profile = Profile.find(params[:id]) profiles=Profile.find(:all, :conditions => ['language=? and id<>? and (parent_name is null or parent_name<>?)', @profile.language, @profile.id, @profile.name], :order => 'name') @@ -212,7 +212,7 @@ class ProfilesController < ApplicationController messages = java_facade.changeParentProfile(id, parent_name) end flash_validation_messages(messages) - redirect_to :action => 'hierarchy', :id => id + redirect_to :action => 'inheritance', :id => id end diff --git a/sonar-server/src/main/webapp/WEB-INF/app/views/profiles/_tabs.html.erb b/sonar-server/src/main/webapp/WEB-INF/app/views/profiles/_tabs.html.erb index c1dad1849de..47ccff6a5f5 100644 --- a/sonar-server/src/main/webapp/WEB-INF/app/views/profiles/_tabs.html.erb +++ b/sonar-server/src/main/webapp/WEB-INF/app/views/profiles/_tabs.html.erb @@ -16,7 +16,7 @@ >Permalinks
  • - >Hierarchy + >Inheritance Tree
  • <% if new_tab %>
  • diff --git a/sonar-server/src/main/webapp/WEB-INF/app/views/profiles/hierarchy.html.erb b/sonar-server/src/main/webapp/WEB-INF/app/views/profiles/inheritance.html.erb similarity index 81% rename from sonar-server/src/main/webapp/WEB-INF/app/views/profiles/hierarchy.html.erb rename to sonar-server/src/main/webapp/WEB-INF/app/views/profiles/inheritance.html.erb index 41c0df853a0..7d3e1c04da9 100644 --- a/sonar-server/src/main/webapp/WEB-INF/app/views/profiles/hierarchy.html.erb +++ b/sonar-server/src/main/webapp/WEB-INF/app/views/profiles/inheritance.html.erb @@ -1,5 +1,5 @@

    <%= link_to 'Quality profiles', :controller => 'profiles', :action => 'index' -%> / <%= h @profile.language -%> / <%= h @profile.name %>

    -<%= render :partial => 'profiles/tabs', :locals => {:selected_tab=>'Hierarchy'} %> +<%= render :partial => 'profiles/tabs', :locals => {:selected_tab=>'inheritance'} %>
    @@ -8,7 +8,7 @@
    <% @profile.ancestors.reverse.each do |parent| %> - <%= parent.name -%> (<%= parent.active_rules.size -%> rules)
    + <%= parent.name -%> (<%= parent.active_rules.size -%> rules)
    <%= image_tag 'blue-up.png' -%>
    <% end %> @@ -18,7 +18,7 @@ <%= image_tag 'blue-up.png' -%>
    <% @profile.children.each_with_index do |child,index| %> <%= ', ' if index>0 -%> - <%= child.name -%> (<%= child.active_rules.size -%> rules) + <%= child.name -%> (<%= child.active_rules.size -%> rules) <% end %>
    <%= image_tag 'blue-up.png' -%>
    ... diff --git a/sonar-server/src/main/webapp/images/up-blue-24.png b/sonar-server/src/main/webapp/images/up-blue-24.png new file mode 100644 index 0000000000000000000000000000000000000000..a3507b3c05895788cfcd31df7a764d4041747797 GIT binary patch literal 928 zcmV;R17G}!P)6G0rtzyIuRb|aBi4_-v7RE>zQw($YJ8f!%l zBIuzvu@MiI66-+`L2VBT^?@Mb1FHwcgBLG~p!mR(Ahu|gqDAq6mO`t+Hi_GP%y`(@ zbkj67S{J^Z*=6VZ&HtO7At3}xz4WE)w}OC?mrw7MIz}zoyehsu-q?HvAQ;sf_LyCd zZ~r%dUKMYs-PL?)+nVL&0KgRGYPhCO`_=jA)}#SO^@g3biR8I0E33*ZmjguDysEmK zl$Og=VjK1Bi-*_$8DLb`?OxxQJX;rAGS!ym1OX5sUbDE2*#7g86`Qp5^9NUpc~G%M zHflCD)ix$iu3ow@0s_dpK_WmzU<~N&d6#~4jsu9_tX|blGtz~KTm7kHP-fRV_H!k4SiL>3bR7!&Bvnh+$QD}{OMD#4iyz;Ya6TXw;$ zLn?VdjbQx&Fz!b4FVptSjWGa2_00X>^q(uxl)^>zH2RC0lZj|--l2f8FKsdv=qhqi z=*6n}n+k~XKBnQ`*Td?sA*LyWQ30w#(3sc%`QimY-~h0tEZL68)&am(Il!N#5>ODJ z%V$M?%cX%80CEWprjS=Q8>1kM1NKI)#NBTI0000