From: Julien Lancelot Date: Wed, 21 Nov 2012 15:31:33 +0000 (+0100) Subject: SONAR-3807 SONAR-3966 Quality profiles improvement X-Git-Tag: 3.4~310 X-Git-Url: https://source.dussan.org/?a=commitdiff_plain;h=567a26eb4e9e0c8ff56767fff4e5263309f7729a;p=sonarqube.git SONAR-3807 SONAR-3966 Quality profiles improvement Do not expand description during disable/enable rule Replace expand/collapse link by to separated links --- diff --git a/plugins/sonar-core-plugin/src/main/resources/org/sonar/l10n/core.properties b/plugins/sonar-core-plugin/src/main/resources/org/sonar/l10n/core.properties index c58cd5f6dc5..ff533f8caf4 100644 --- a/plugins/sonar-core-plugin/src/main/resources/org/sonar/l10n/core.properties +++ b/plugins/sonar-core-plugin/src/main/resources/org/sonar/l10n/core.properties @@ -1263,7 +1263,8 @@ rules_configuration.tab.new_rule=New rule rules_configuration.tab.edit_rule=Edit rule rules_configuration.x_found_in_active_rules={0} found in active rules rules_configuration.x_found_in_inactive_rules={0} found in inactive rules -rules_configuration.expand_collapse=expand/collapse +rules_configuration.expand=expand +rules_configuration.collapse=collapse rules_configuration.html_allowed=HTML is allowed. rules_configuration.inherited_from_parent=Inherited from parent rules_configuration.overrides_parent_definition=Overrides parent definition diff --git a/sonar-server/src/main/webapp/WEB-INF/app/views/rules_configuration/_rule.html.erb b/sonar-server/src/main/webapp/WEB-INF/app/views/rules_configuration/_rule.html.erb index 2476e28d9b5..9d0dfe1d246 100644 --- a/sonar-server/src/main/webapp/WEB-INF/app/views/rules_configuration/_rule.html.erb +++ b/sonar-server/src/main/webapp/WEB-INF/app/views/rules_configuration/_rule.html.erb @@ -34,7 +34,7 @@ end %> -
+
diff --git a/sonar-server/src/main/webapp/WEB-INF/app/views/rules_configuration/index.html.erb b/sonar-server/src/main/webapp/WEB-INF/app/views/rules_configuration/index.html.erb index 043a859d694..8ad6dda5d6a 100644 --- a/sonar-server/src/main/webapp/WEB-INF/app/views/rules_configuration/index.html.erb +++ b/sonar-server/src/main/webapp/WEB-INF/app/views/rules_configuration/index.html.erb @@ -19,9 +19,14 @@ } return !localModifications; } - function toggle_rules(){ + function expand_rules(){ $$('.rule_detail').each(function(element) { - element.toggle(); + element.show(); + }); + } + function collapse_rules(){ + $$('.rule_detail').each(function(element) { + element.hide(); }); } @@ -99,7 +104,7 @@ <%= message('active') -%>/<%= message('severity') -%> - <%= message('name') -%> [<%= link_to_function(message('rules_configuration.expand_collapse'), "toggle_rules()") %>] + <%= message('name') -%> [<%= link_to_function(message('rules_configuration.expand'), "expand_rules()") %> / <%= link_to_function(message('rules_configuration.collapse'), "collapse_rules()") %>]