mirror of
https://github.com/fusionpbx/fusionpbx.git
synced 2025-12-30 00:53:50 +00:00
Set the default ring group destination order.
This commit is contained in:
@@ -70,7 +70,12 @@ require_once "resources/paging.php";
|
||||
//prepare to page the results
|
||||
$sql = "select count(*) as num_rows from v_ring_groups ";
|
||||
$sql .= "where domain_uuid = '$domain_uuid' ";
|
||||
if (strlen($order_by)> 0) { $sql .= "order by $order_by $order "; }
|
||||
if (strlen($order_by) == 0) {
|
||||
$sql .= "order by destination_delay, destination_number asc ";
|
||||
}
|
||||
else {
|
||||
$sql .= "order by $order_by $order ";
|
||||
}
|
||||
$prep_statement = $db->prepare($sql);
|
||||
if ($prep_statement) {
|
||||
$prep_statement->execute();
|
||||
@@ -94,7 +99,12 @@ require_once "resources/paging.php";
|
||||
//get the list
|
||||
$sql = "select * from v_ring_groups ";
|
||||
$sql .= "where domain_uuid = '$domain_uuid' ";
|
||||
if (strlen($order_by)> 0) { $sql .= "order by $order_by $order "; }
|
||||
if (strlen($order_by) == 0) {
|
||||
$sql .= "order by destination_delay, destination_number asc ";
|
||||
}
|
||||
else {
|
||||
$sql .= "order by $order_by $order ";
|
||||
}
|
||||
$sql .= " limit $rows_per_page offset $offset ";
|
||||
$prep_statement = $db->prepare(check_sql($sql));
|
||||
$prep_statement->execute();
|
||||
|
||||
Reference in New Issue
Block a user