Add sort for services for group then service

This commit is contained in:
Sejin Kim 2022-12-20 10:26:39 -05:00 committed by GitHub
parent c9bcbc241b
commit 2d65d0f9df
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -73,7 +73,7 @@ class Constellation
global $mysqli;
//$query = $mysqli->query("SELECT id, name, description FROM services");
$query = $mysqli->query("SELECT services.id, services.name, services.description, services_groups.name as group_name FROM services LEFT JOIN services_groups ON services.group_id=services_groups.id ORDER BY services_groups.name ");
$query = $mysqli->query("SELECT services.id, services.name, services.description, services_groups.name as group_name FROM services LEFT JOIN services_groups ON services.group_id=services_groups.id ORDER BY services_groups.name ASC, services.name;");
$array = array();
if ($query->num_rows){
$timestamp = time();