Commit version 24.12.13800

This commit is contained in:
2025-01-06 17:35:06 -05:00
parent b7f6a79c2c
commit 55d9218816
6133 changed files with 4239740 additions and 1374287 deletions

View File

@ -1,5 +1,4 @@
<?php
/**
* Observium
*
@ -7,31 +6,26 @@
*
* @package observium
* @subpackage graphs
* @copyright (C) 2006-2013 Adam Armstrong, (C) 2013-2019 Observium Limited
* @copyright (C) Adam Armstrong
*
*/
if (is_numeric($vars['id']) && $alert = get_alert_entry_by_id($vars['id']))
{
if (is_intnum($vars['id']) && $alert = get_alert_entry_by_id($vars['id'])) {
$entity = get_entity_by_id_cache($alert['entity_type'], $alert['entity_id']);
$device = device_by_id_cache($alert['device_id']);
if (device_permitted($device['device_id']) || $auth)
{
if (device_permitted($device['device_id']) || $auth) {
$entity = get_entity_by_id_cache($alert['entity_type'], $alert['entity_id']);
$title = generate_device_link($device);
$rrd_filename = get_rrd_path($device, "alert-" . $alert['alert_test_id'] . "-" . $alert['entity_type'] . "-" . $alert['entity_id'] . ".rrd");
$auth = TRUE;
$title_array = array();
$title_array[] = array('text' => $device['hostname'], 'url' => generate_url(array('page' => 'device', 'device' => $device['device_id'])));
$auth = TRUE;
$rrd_filename = get_rrd_path($device, "alert-".$alert['alert_test_id']."-".$alert['entity_type']."-".$alert['entity_id'].".rrd");
$title_array = [];
$title_array[] = [ 'text' => $device['hostname'],
'url' => generate_url(['page' => 'device', 'device' => $device['device_id']]) ];
$graph_title = device_name($device, TRUE);
}
} else {
// error?
}
?>
// EOF

View File

@ -5,9 +5,9 @@
*
* This file is part of Observium.
*
* @package observium
* @subpackage graphs
* @copyright (C) 2006-2013 Adam Armstrong, (C) 2013-2019 Observium Limited
* @package observium
* @subpackage graphs
* @copyright (C) Adam Armstrong
*
*/
@ -15,12 +15,12 @@ $scale_min = "0";
$scale_max = "1";
$step = TRUE;
include_once($config['html_dir']."/includes/graphs/common.inc.php");
include_once($config['html_dir'] . "/includes/graphs/common.inc.php");
$rrd_options .= " COMMENT:' Min Last Max\\n'";
$rrd_options .= " DEF:status=".$rrd_filename_escape.":status:AVERAGE";
$rrd_options .= " DEF:code=".$rrd_filename_escape.":code:AVERAGE";
$rrd_options .= " DEF:status=" . $rrd_filename_escape . ":status:AVERAGE";
$rrd_options .= " DEF:code=" . $rrd_filename_escape . ":code:AVERAGE";
$rrd_options .= " CDEF:percent=status,UN,UNKN,status,IF,100,* ";