diff --git a/pandora_console/include/functions_reporting.php b/pandora_console/include/functions_reporting.php index 4c7438ebb8..09322c7a8c 100755 --- a/pandora_console/include/functions_reporting.php +++ b/pandora_console/include/functions_reporting.php @@ -8682,8 +8682,8 @@ function reporting_availability($report, $content, $date=false, $time=false) $item['id_agent_module'] ); - if (isset($item['compare']) === true - && empty($item['compare']) === true + if (isset($item['compare']) === false + || empty($item['compare']) === true ) { $row['data']['compare'] = false; } else { diff --git a/pandora_console/include/functions_reporting_html.php b/pandora_console/include/functions_reporting_html.php index cd764dbf32..0b0fcf3a74 100644 --- a/pandora_console/include/functions_reporting_html.php +++ b/pandora_console/include/functions_reporting_html.php @@ -4007,7 +4007,7 @@ function reporting_html_text(&$table, $item) */ function reporting_html_availability($table, $item, $pdf=0) { - $retun_pdf = ''; + $return_pdf = ''; $style = db_get_value( 'style', @@ -4234,7 +4234,7 @@ function reporting_html_availability($table, $item, $pdf=0) } else { $table_row[] = $row['agent']; $item_name = $row['availability_item']; - if ((bool) $row['compare'] === false) { + if ((bool) $row['compare'] === true) { $item_name .= ' ('.__('24 x 7').')'; } @@ -4422,6 +4422,7 @@ function reporting_html_availability($table, $item, $pdf=0) $table2->data[] = $table_row2; } } else { + $table = new stdClass(); $table->colspan['error']['cell'] = 3; $table->data['error']['cell'] = __( 'There are no Agent/Modules defined'