From efbb3df738767183a21eab7170eef38022a5a0b7 Mon Sep 17 00:00:00 2001 From: Carlos Morais + Diego Araújo Date: Fri, 3 Feb 2012 17:05:02 +0300 Subject: [PATCH] Show metric weight on results --- plugins/mezuro/lib/kalibro/entities/metric_result.rb | 4 ++-- plugins/mezuro/views/content_viewer/_module_result.rhtml | 7 +++---- 2 files changed, 5 insertions(+), 6 deletions(-) diff --git a/plugins/mezuro/lib/kalibro/entities/metric_result.rb b/plugins/mezuro/lib/kalibro/entities/metric_result.rb index 65e1ae0..6904421 100644 --- a/plugins/mezuro/lib/kalibro/entities/metric_result.rb +++ b/plugins/mezuro/lib/kalibro/entities/metric_result.rb @@ -1,6 +1,6 @@ class Kalibro::Entities::MetricResult < Kalibro::Entities::Entity - attr_accessor :metric, :value, :range, :descendent_result + attr_accessor :metric, :value, :range, :descendent_result, :weight def metric=(value) if value.kind_of?(Hash) @@ -30,4 +30,4 @@ class Kalibro::Entities::MetricResult < Kalibro::Entities::Entity @descendent_result = descendent_results end -end \ No newline at end of file +end diff --git a/plugins/mezuro/views/content_viewer/_module_result.rhtml b/plugins/mezuro/views/content_viewer/_module_result.rhtml index 3fa18a7..9b17224 100644 --- a/plugins/mezuro/views/content_viewer/_module_result.rhtml +++ b/plugins/mezuro/views/content_viewer/_module_result.rhtml @@ -1,4 +1,3 @@ -
<%= _('Metric Result') %>
<%= _('Module:') %> @@ -11,7 +10,7 @@ Metric Value - + Weight Threshold @@ -20,7 +19,7 @@ <%= metric_result.metric.name %> <%= metric_result.value %> - + <%= metric_result.weight %> <% range = metric_result.range %> <%= range.label %> @@ -28,7 +27,7 @@ - + <%= _('Grade:') %> <%= module_result.grade %> -- libgit2 0.21.2