diff --git a/module/metric/calc/execution/scale/count_of_bug_in_type_in_execution.php b/module/metric/calc/execution/scale/count_of_bug_in_type_in_execution.php index 58268521de..28e09cdef4 100644 --- a/module/metric/calc/execution/scale/count_of_bug_in_type_in_execution.php +++ b/module/metric/calc/execution/scale/count_of_bug_in_type_in_execution.php @@ -12,4 +12,17 @@ class count_of_bug_in_type_in_execution extends baseCalc if(!isset($this->result[$row->type])) $this->result[$row->type] = array(); $this->result[$row->type][$row->id] = $row->id; } + + public function getResult($options = array()) + { + foreach($this->result as $type => $bugs) + { + if(!is_array($bugs)) continue; + + $this->result[$type] = count($bugs); + } + + $records = $this->getRecords(array('type', 'value')); + return $this->filterByOptions($records, $options); + } }