Adding ORDER BY so device groups are sorted by name instead of creation.

Currently the function for retrieving device_groups returns rows in the order
in which they were created.  This causes the WebUI to display is a semi-random
order.  This patch causes the devices to be sorted by name which makes the
group lists easier to navigate.
This commit is contained in:
David M. Syzdek
2015-08-03 15:18:21 -08:00
parent 23286480c5
commit b5db25c436

View File

@@ -92,7 +92,7 @@ function GetDevicesFromGroup($group_id) {
* @return array
*/
function GetDeviceGroups() {
return dbFetchRows('SELECT * FROM device_groups');
return dbFetchRows('SELECT * FROM device_groups ORDER BY name');
}//end GetDeviceGroups()