* finish task #2929.

This commit is contained in:
pengjiangxiu
2017-02-24 14:52:48 +08:00
parent 0a00ab84a8
commit 1d893447eb
3 changed files with 16 additions and 1 deletions
+14
View File
@@ -1622,6 +1622,20 @@ class bugModel extends model
return $datas;
}
/**
* Get report data of bugs per pri
*
* @access public
* @return array
*/
public function getDataOfBugsPerPri()
{
$datas = $this->dao->select('pri AS name, COUNT(*) AS value')->from(TABLE_BUG)->where($this->reportCondition())->groupBy('name')->orderBy('value DESC')->fetchAll('name');
if(!$datas) return array();
foreach($datas as $status => $data) if(isset($this->lang->bug->statusList[$status])) $data->name = $this->lang->bug->statusList[$status];
return $datas;
}
/**
* Get report data of bugs per status.
*