mirror of
https://github.com/librenms/librenms.git
synced 2024-10-07 16:52:45 +00:00
Apply fixes from StyleCI (#14899)
Co-authored-by: StyleCI Bot <bot@styleci.io>
This commit is contained in:
@@ -105,7 +105,7 @@ if (! isset($vars['sort']) || empty($vars['sort'])) {
|
||||
$sql .= " ORDER BY $sort";
|
||||
|
||||
if (isset($current)) {
|
||||
$limit_low = (($current * $rowCount) - ($rowCount));
|
||||
$limit_low = (($current * $rowCount) - $rowCount);
|
||||
$limit_high = $rowCount;
|
||||
}
|
||||
|
||||
@@ -145,7 +145,7 @@ foreach (dbFetchRows($sql, $param) as $alert) {
|
||||
}
|
||||
}
|
||||
|
||||
$hostname = '<div class="incident">' . generate_device_link($alert, shorthost(format_hostname($alert))) . '<div id="incident' . ($alert['id']) . '"';
|
||||
$hostname = '<div class="incident">' . generate_device_link($alert, shorthost(format_hostname($alert))) . '<div id="incident' . $alert['id'] . '"';
|
||||
if (is_numeric($vars['uncollapse_key_count'])) {
|
||||
$hostname .= $max_row_length < (int) $vars['uncollapse_key_count'] ? '' : ' class="collapse"';
|
||||
} else {
|
||||
@@ -186,7 +186,7 @@ foreach (dbFetchRows($sql, $param) as $alert) {
|
||||
$response[] = [
|
||||
'id' => $rulei++,
|
||||
'rule' => '<i title="' . htmlentities($alert['rule']) . '"><a href="' . \LibreNMS\Util\Url::generate(['page' => 'alert-rules']) . '">' . htmlentities($alert['name']) . '</a></i>',
|
||||
'details' => '<a class="fa-solid fa-plus incident-toggle" style="display:none" data-toggle="collapse" data-target="#incident' . ($alert['id']) . '" data-parent="#alerts"></a>',
|
||||
'details' => '<a class="fa-solid fa-plus incident-toggle" style="display:none" data-toggle="collapse" data-target="#incident' . $alert['id'] . '" data-parent="#alerts"></a>',
|
||||
'verbose_details' => "<button type='button' class='btn btn-alert-details command-alert-details' aria-label='Details' id='alert-details' data-alert_log_id='{$alert_log_id}'><i class='fa-solid fa-circle-info'></i></button>",
|
||||
'hostname' => $hostname,
|
||||
'location' => generate_link($alert['location'], ['page' => 'devices', 'location' => $alert['location']]),
|
||||
|
Reference in New Issue
Block a user