Skip to content
This repository has been archived by the owner on Dec 13, 2022. It is now read-only.

Commit

Permalink
feat(chart): add legend name when defined
Browse files Browse the repository at this point in the history
  • Loading branch information
cgagnaire authored and kduret committed Oct 31, 2017
1 parent 0d5b19d commit 1bc711c
Showing 1 changed file with 7 additions and 0 deletions.
7 changes: 7 additions & 0 deletions www/class/centreonGraph.class.php
Original file line number Diff line number Diff line change
Expand Up @@ -554,7 +554,14 @@ public function initCurveList()
($ds_val['service_id'] == $metric['service_id'] || $ds_val['service_id'] == '') &&
preg_match($metricPattern, $metric['metric_name'])) {
$ds_data_associated = $ds_val;
if ($ds_val['ds_legend'] != '') {
$this->metrics[$metric["metric_id"]]["metric_legend"] = $ds_val['ds_legend'];
}
break;
} else {
if (preg_match($metricPattern, $metric['metric_name']) && $ds_val['ds_legend'] != '') {
$this->metrics[$metric["metric_id"]]["metric_legend"] = $ds_val['ds_legend'];
}
}

/* Check regular */
Expand Down

0 comments on commit 1bc711c

Please sign in to comment.