Minor fix SLA graph

This commit is contained in:
fbsanchez 2016-11-29 17:51:01 +01:00
parent b8d7a94eb8
commit d5c61771d7
1 changed files with 5 additions and 5 deletions

View File

@ -683,18 +683,18 @@ function reporting_SLA($report, $content, $type = 'dinamic',
// generate raw data for graph
if ($value_sla['time_total'] != 0) {
if ($value_sla['time_unknown'] == $value_sla['time_total']) { // UNKNOWN
if ($value_sla['time_error'] > 0) { // ERR
$raw_graph[$i]['data'] = 3;
}
elseif ($value_sla['time_unknown'] > 0) { // UNKNOWN
$raw_graph[$i]['data'] = 4;
}
elseif ($value_sla['time_not_init'] == $value_sla['time_total']) { // NOT INIT
$raw_graph[$i]['data'] = 6;
}
elseif ($value_sla['SLA'] >= $sla['sla_limit']) { // OK
else {
$raw_graph[$i]['data'] = 1;
}
elseif ($value_sla['SLA'] < $sla['sla_limit']) { // ERR
$raw_graph[$i]['data'] = 3;
}
}
else {
$raw_graph[$i]['data'] = 7;