Skip to content

Commit bc4dcac

Browse files
authored
Update the ordering of sensors for Overview page (librenms#17038)
1 parent ad4ce9c commit bc4dcac

File tree

1 file changed

+4
-1
lines changed

1 file changed

+4
-1
lines changed

includes/html/pages/device/overview/generic/sensor.inc.php

Lines changed: 4 additions & 1 deletion
Original file line numberDiff line numberDiff line change
@@ -1,6 +1,9 @@
11
<?php
22

3-
$sensors = DeviceCache::getPrimary()->sensors->where('sensor_class', $sensor_class)->where('group', '!=', 'transceiver'); // cache all sensors on device and exclude transceivers
3+
$sensors = DeviceCache::getPrimary()->sensors->where('sensor_class', $sensor_class)->where('group', '!=', 'transceiver')->sortBy([
4+
['group', 'asc'],
5+
['sensor_descr', 'asc'],
6+
]); // cache all sensors on device and exclude transceivers
47

58
if ($sensors->isNotEmpty()) {
69
$icons = \App\Models\Sensor::getIconMap();

0 commit comments

Comments
 (0)