fixed error massive services operations pandora_enterprise#9262

This commit is contained in:
Daniel Barbero 2022-09-12 12:44:10 +02:00
parent 06be85e044
commit 958fb6c563
1 changed files with 13 additions and 18 deletions

View File

@ -7746,16 +7746,8 @@ function reporting_advanced_sla(
}
if (isset($max_value) === false || (int) $max_value === 0) {
if ($max_value === '0'
&& $max_value < $min_value
&& isset($min_value_warning) === true
&& $min_value_warning > $max_value
) {
$max_value = $min_value_warning;
} else {
$max_value = null;
}
}
if (isset($max_value) === false && isset($min_value) === false) {
$max_value = null;
@ -8309,6 +8301,8 @@ function reporting_advanced_sla(
$inverse_interval
);
$sla_check_value_warning = false;
if ($sla_check_value === true) {
// Warning SLA check.
$sla_check_value_warning = sla_check_value(
$current_data['datos'],
@ -8318,9 +8312,10 @@ function reporting_advanced_sla(
1
);
}
}
// Not unknown nor not init values.
if ($sla_check_value_warning && $sla_check_warning === true) {
if ($sla_check_value_warning === true && $sla_check_warning === true) {
if (isset($current_data['type']) === false
|| ((int) $current_data['type'] === 0
&& $i !== 0)