aboutsummaryrefslogtreecommitdiffstats
path: root/plugins
diff options
context:
space:
mode:
authorStas Vilchik <vilchiks@gmail.com>2014-07-04 17:31:16 +0600
committerStas Vilchik <vilchiks@gmail.com>2014-07-04 17:31:16 +0600
commit7a506bfd556e798e605ba305af91c5d18eee81f3 (patch)
treef1dd04f264b11a7d9ce931c7c9bf35aaff7ac114 /plugins
parentbc7dddf031537bc5a658573c63f7bc9d73e633cb (diff)
downloadsonarqube-7a506bfd556e798e605ba305af91c5d18eee81f3.tar.gz
sonarqube-7a506bfd556e798e605ba305af91c5d18eee81f3.zip
SONAR-5207 Fix widget html path
Diffstat (limited to 'plugins')
-rw-r--r--plugins/sonar-core-plugin/src/main/java/org/sonar/plugins/core/widgets/measures/MeasureFilterAsTreemapWidget.java8
-rw-r--r--plugins/sonar-core-plugin/src/main/resources/org/sonar/plugins/core/widgets/measures/measure_filter_treemap.html.erb (renamed from plugins/sonar-core-plugin/src/main/resources/org/sonar/plugins/core/widgets/measure_filter_treemap.html.erb)0
2 files changed, 5 insertions, 3 deletions
diff --git a/plugins/sonar-core-plugin/src/main/java/org/sonar/plugins/core/widgets/measures/MeasureFilterAsTreemapWidget.java b/plugins/sonar-core-plugin/src/main/java/org/sonar/plugins/core/widgets/measures/MeasureFilterAsTreemapWidget.java
index ae959dd25ce..2d21ec1ed4c 100644
--- a/plugins/sonar-core-plugin/src/main/java/org/sonar/plugins/core/widgets/measures/MeasureFilterAsTreemapWidget.java
+++ b/plugins/sonar-core-plugin/src/main/java/org/sonar/plugins/core/widgets/measures/MeasureFilterAsTreemapWidget.java
@@ -19,6 +19,7 @@
*/
package org.sonar.plugins.core.widgets.measures;
+import org.sonar.api.measures.CoreMetrics;
import org.sonar.api.web.*;
import org.sonar.plugins.core.widgets.CoreWidget;
import org.sonar.plugins.core.widgets.WidgetConstants;
@@ -32,9 +33,10 @@ import static org.sonar.api.web.WidgetScope.GLOBAL;
optional = false),
@WidgetProperty(key = MeasureFilterAsTreemapWidget.CHART_TITLE_PROPERTY, type = WidgetPropertyType.STRING),
@WidgetProperty(key = MeasureFilterAsTreemapWidget.SIZE_METRIC_PROPERTY, type = WidgetPropertyType.METRIC,
- optional = true, options = { WidgetConstants.FILTER_OUT_NEW_METRICS }),
+ defaultValue = CoreMetrics.COMPLEXITY_KEY, options = { WidgetConstants.FILTER_OUT_NEW_METRICS }),
@WidgetProperty(key = MeasureFilterAsTreemapWidget.COLOR_METRIC_PROPERTY, type = WidgetPropertyType.METRIC,
- optional = true, options = { WidgetConstants.FILTER_OUT_NEW_METRICS, "type:PERCENT,RATING,LEVEL" }),
+ defaultValue = CoreMetrics.COVERAGE_KEY,
+ options = { WidgetConstants.FILTER_OUT_NEW_METRICS, "type:PERCENT,RATING,LEVEL" }),
@WidgetProperty(key = MeasureFilterAsTreemapWidget.HEIGHT_PERCENTS_PROPERTY, type = WidgetPropertyType.INTEGER,
optional = true, defaultValue = "55", description = "Height in percents of width"),
@WidgetProperty(key = MeasureFilterAsTreemapWidget.MAX_ITEMS_PROPERTY, type = WidgetPropertyType.INTEGER,
@@ -50,6 +52,6 @@ public class MeasureFilterAsTreemapWidget extends CoreWidget {
public static final String ID = "measure_filter_treemap";
public MeasureFilterAsTreemapWidget() {
- super(ID, "Measure Filter as Treemap", "/Users/Stas/Projects/sonar/plugins/sonar-core-plugin/src/main/resources/org/sonar/plugins/core/widgets/measure_filter_treemap.html.erb");
+ super(ID, "Measure Filter as Treemap", "/org/sonar/plugins/core/widgets/measures/measure_filter_treemap.html.erb");
}
}
diff --git a/plugins/sonar-core-plugin/src/main/resources/org/sonar/plugins/core/widgets/measure_filter_treemap.html.erb b/plugins/sonar-core-plugin/src/main/resources/org/sonar/plugins/core/widgets/measures/measure_filter_treemap.html.erb
index 67d2bd13cfb..67d2bd13cfb 100644
--- a/plugins/sonar-core-plugin/src/main/resources/org/sonar/plugins/core/widgets/measure_filter_treemap.html.erb
+++ b/plugins/sonar-core-plugin/src/main/resources/org/sonar/plugins/core/widgets/measures/measure_filter_treemap.html.erb