From fb4be3cddf3addc6edc158e9fc84a397299b8a93 Mon Sep 17 00:00:00 2001 From: fermin831 Date: Wed, 11 Apr 2018 16:22:16 +0200 Subject: [PATCH] [SLA] Substitute the downplanned color --- pandora_console/images/square_violet.png | Bin 0 -> 184 bytes pandora_console/include/constants.php | 2 ++ pandora_console/include/functions_graph.php | 4 ++-- .../include/functions_reporting_html.php | 8 ++++---- 4 files changed, 8 insertions(+), 6 deletions(-) create mode 100644 pandora_console/images/square_violet.png diff --git a/pandora_console/images/square_violet.png b/pandora_console/images/square_violet.png new file mode 100644 index 0000000000000000000000000000000000000000..877b43871da04d58f6d2202805362b731a733330 GIT binary patch literal 184 zcmeAS@N?(olHy`uVBq!ia0vp@Ak4uAB#T}@sR2?f#ZI0f96(URkDQ-L4n65p8MmrdB=+@Y{a+e{b}f$=;!2gXiui(%wsn>JuehZ^*h1+gTe~DWM4fpj${S literal 0 HcmV?d00001 diff --git a/pandora_console/include/constants.php b/pandora_console/include/constants.php index cb0069cf10..a4aaefbbe9 100644 --- a/pandora_console/include/constants.php +++ b/pandora_console/include/constants.php @@ -129,6 +129,8 @@ define('COL_WARNING_DARK', '#FFB900'); define('COL_NORMAL', '#80BA27'); define('COL_NOTINIT', '#3BA0FF'); define('COL_UNKNOWN', '#B2B2B2'); +define('COL_DOWNTIME', '#976DB1'); +define('COL_IGNORED', '#DDD'); define('COL_ALERTFIRED', '#FFA631'); define('COL_MINOR', '#F099A2'); define('COL_MAJOR', '#C97A4A'); diff --git a/pandora_console/include/functions_graph.php b/pandora_console/include/functions_graph.php index 787283fce2..5be7f386c3 100644 --- a/pandora_console/include/functions_graph.php +++ b/pandora_console/include/functions_graph.php @@ -2843,9 +2843,9 @@ function graph_sla_slicebar ($id, $period, $sla_min, $sla_max, $date, $daysWeek 2 => COL_WARNING, 3 => COL_CRITICAL, 4 => COL_UNKNOWN, - 5 => "#ff8400",//COL_MINOR, + 5 => COL_DOWNTIME, 6 => COL_NOTINIT, - 7 => "#ddd");//COL_MAJOR); + 7 => COL_IGNORED); return slicesbar_graph($data, $period, $width, $height, $colors, $config['fontpath'], $round_corner, $home_url, $ttl); diff --git a/pandora_console/include/functions_reporting_html.php b/pandora_console/include/functions_reporting_html.php index 619f986d63..60e793ef4e 100644 --- a/pandora_console/include/functions_reporting_html.php +++ b/pandora_console/include/functions_reporting_html.php @@ -535,7 +535,7 @@ function reporting_html_SLA($table, $item, $mini) { $row2[] = '--'; if($sla['time_downtime'] != 0) - $row2[] = '' . human_time_description_raw($sla['time_downtime'], true) . ''; + $row2[] = '' . human_time_description_raw($sla['time_downtime'], true) . ''; else $row2[] = '--'; @@ -614,7 +614,7 @@ function reporting_html_SLA($table, $item, $mini) { $row2[] = '--'; if($sla['time_downtime'] != 0) - $row2[] = '' . human_time_description_raw($sla['time_downtime'], true) . ''; + $row2[] = ''. human_time_description_raw($sla['time_downtime'], true) . ''; else $row2[] = '--'; @@ -693,7 +693,7 @@ function reporting_html_SLA($table, $item, $mini) { $table1->data[0][7] = ''.__('Not Init'). ''; $table1->size[8] = '2%'; - $table1->data[0][8] = ''; + $table1->data[0][8] = ''; $table1->size[9] = '14%'; $table1->data[0][9] = ''.__('Downtimes'). ''; @@ -2612,7 +2612,7 @@ function reporting_html_availability_graph(&$table, $item, $pdf=0) { $table2->data[0][7] = ''.__('Not Init'). ''; $table2->size[8] = '2%'; - $table2->data[0][8] = ''; + $table2->data[0][8] = ''; $table2->size[9] = '14%'; $table2->data[0][9] = ''.__('Downtimes'). '';