aboutsummaryrefslogtreecommitdiffstats
path: root/plugins
diff options
context:
space:
mode:
authorJean-Baptiste Lievremont <jean-baptiste.lievremont@sonarsource.com>2014-10-03 15:45:54 +0200
committerJean-Baptiste Lievremont <jean-baptiste.lievremont@sonarsource.com>2014-10-03 15:46:14 +0200
commite7194d297211fb57ac548a7c796d9644716482e4 (patch)
treee21a87fa4e855a52d2d6b29111e91fd654ad75f1 /plugins
parent3406907abc194c2a665539f49cea1a16f877e667 (diff)
downloadsonarqube-e7194d297211fb57ac548a7c796d9644716482e4.tar.gz
sonarqube-e7194d297211fb57ac548a7c796d9644716482e4.zip
SONAR-5617 Update package_design widget
Diffstat (limited to 'plugins')
-rw-r--r--plugins/sonar-design-plugin/src/main/java/org/sonar/plugins/design/ui/widgets/PackageDesignWidget.java2
-rw-r--r--plugins/sonar-design-plugin/src/main/resources/org/sonar/plugins/design/ui/widgets/package_design.html.erb11
2 files changed, 7 insertions, 6 deletions
diff --git a/plugins/sonar-design-plugin/src/main/java/org/sonar/plugins/design/ui/widgets/PackageDesignWidget.java b/plugins/sonar-design-plugin/src/main/java/org/sonar/plugins/design/ui/widgets/PackageDesignWidget.java
index f5d18f61c2f..d79f9337d68 100644
--- a/plugins/sonar-design-plugin/src/main/java/org/sonar/plugins/design/ui/widgets/PackageDesignWidget.java
+++ b/plugins/sonar-design-plugin/src/main/java/org/sonar/plugins/design/ui/widgets/PackageDesignWidget.java
@@ -33,7 +33,7 @@ public final class PackageDesignWidget extends AbstractRubyTemplate implements R
}
public String getTitle() {
- return "Package design";
+ return "File design";
}
@Override
diff --git a/plugins/sonar-design-plugin/src/main/resources/org/sonar/plugins/design/ui/widgets/package_design.html.erb b/plugins/sonar-design-plugin/src/main/resources/org/sonar/plugins/design/ui/widgets/package_design.html.erb
index 5d9b7a2c796..b036433449a 100644
--- a/plugins/sonar-design-plugin/src/main/resources/org/sonar/plugins/design/ui/widgets/package_design.html.erb
+++ b/plugins/sonar-design-plugin/src/main/resources/org/sonar/plugins/design/ui/widgets/package_design.html.erb
@@ -4,6 +4,7 @@
package_cycles=measure('package_cycles')
package_feedback_edges=measure('package_feedback_edges')
package_tangles=measure('package_tangles')
+ dsm_url = ApplicationController.root_context + '/design/index/' + @resource.key
%>
<div class="widget-row">
<div class="widget-span widget-span-5">
@@ -11,7 +12,7 @@
<div class="widget-measure widget-measure-main">
<span class="widget-label"><%= message('widget.package_design.package_tangle_index') -%></span>
<span class="nowrap">
- <%= format_measure(package_tangle_index, :suffix => '', :default => '-', :url => url_for_drilldown(package_tangle_index)) %>
+ <%= format_measure(package_tangle_index, :suffix => '', :default => '-', :url => dsm_url) %>
<%= dashboard_configuration.selected_period? ? format_variation(package_tangle_index) : trend_icon(package_tangle_index) -%>
</span>
</div>
@@ -21,7 +22,7 @@
<span class="widget-label"><%= message('widget.package_design.cycles.suffix') -%></span>
<span class="nowrap">
<span class="widget-medium">&gt;</span>
- <%= format_measure(package_cycles, :default => '-', :url => url_for_drilldown(package_cycles)) %>
+ <%= format_measure(package_cycles, :default => '-', :url => dsm_url) %>
<%= dashboard_configuration.selected_period? ? format_variation(package_cycles) : trend_icon(package_cycles) -%>
</span>
</div>
@@ -39,7 +40,7 @@
<div class="widget-measure">
<span class="widget-label"><%= message('widget.package_design.between_packages.suffix') -%></span>
<span class="nowrap">
- <%= format_measure(package_feedback_edges, :default => '-', :url => url_for_drilldown(package_feedback_edges)) %>
+ <%= format_measure(package_feedback_edges, :default => '-', :url => dsm_url) %>
<%= dashboard_configuration.selected_period? ? format_variation(package_feedback_edges) : trend_icon(package_feedback_edges) -%>
</span>
</div>
@@ -49,7 +50,7 @@
<div class="widget-measure">
<span class="widget-label"><%= message('widget.package_design.between_files.suffix') -%></span>
<span class="nowrap">
- <%= format_measure(package_tangles, :default => '-', :url => url_for_drilldown(package_tangles)) %>
+ <%= format_measure(package_tangles, :default => '-', :url => dsm_url) %>
<%= dashboard_configuration.selected_period? ? format_variation(package_tangles) : trend_icon(package_tangles) -%>
</span>
</div>
@@ -58,4 +59,4 @@
</div>
</div>
-<% end %> \ No newline at end of file
+<% end %>