Skip to content

Commit

Permalink
Small changes to include global categories in graph
Browse files Browse the repository at this point in the history
and to hide empty values

Fixes #012293
  • Loading branch information
VeMag authored and rombert committed Apr 30, 2012
1 parent 78a6312 commit c4ad6d8
Showing 1 changed file with 3 additions and 2 deletions.
5 changes: 3 additions & 2 deletions plugins/MantisGraph/core/graph_api.php
Expand Up @@ -752,7 +752,7 @@ function create_category_summary() {

$query = "SELECT id, name
FROM $t_cat_table
WHERE $specific_where
WHERE $specific_where or project_id=" . ALL_PROJECTS . "

This comment has been minimized.

Copy link
@atrol

atrol May 1, 2012

Member

Please have a look at our coding conventions
http://www.mantisbt.org/guidelines.php
Reserved SQL keywords should be UPPERCASE.

This comment has been minimized.

Copy link
@rombert

rombert May 1, 2012

Member

Fixed, thanks!

ORDER BY name";
$result = db_query_bound( $query );
$category_count = db_num_rows( $result );
Expand All @@ -769,7 +769,8 @@ function create_category_summary() {
if ( isset($t_metrics[$t_cat_name]) ) {
$t_metrics[$t_cat_name] = $t_metrics[$t_cat_name] + db_result( $result2, 0, 0 );
} else {
$t_metrics[$t_cat_name] = db_result( $result2, 0, 0 );
if (db_result( $result2, 0, 0 ) > 0)
$t_metrics[$t_cat_name] = db_result( $result2, 0, 0 );
}
}

Expand Down

0 comments on commit c4ad6d8

Please sign in to comment.