fix orphan v_ring_group_users after deleting ring group (#2110)
* fix orphan v_ring_group_users after deleting ring group steps to test: create a ring group with one extension and one user. This will add one user to v_ring_group_users. Delete the ring group. expected result: ring group and all it's components are deleted actual result v_ring_group_user entry for this ring group is not deleted. This fix: deletes v_ring_group_user when ring group is deleted. * Update ring_group_delete.php * Update ring_group_delete.php Remove the hidden spaces
This commit is contained in:
parent
b5099c1e77
commit
b36051f73f
|
|
@ -73,6 +73,13 @@ else {
|
||||||
$db->exec(check_sql($sql));
|
$db->exec(check_sql($sql));
|
||||||
unset($sql);
|
unset($sql);
|
||||||
|
|
||||||
|
//delete the ring group users
|
||||||
|
$sql = "delete from v_ring_group_users ";
|
||||||
|
$sql .= "where domain_uuid = '".$_SESSION['domain_uuid']."' ";
|
||||||
|
$sql .= "and ring_group_uuid = '".$id."' ";
|
||||||
|
$db->exec(check_sql($sql));
|
||||||
|
unset($sql);
|
||||||
|
|
||||||
//delete the dialplan details
|
//delete the dialplan details
|
||||||
$sql = "delete from v_dialplan_details ";
|
$sql = "delete from v_dialplan_details ";
|
||||||
$sql .= "where domain_uuid = '".$_SESSION['domain_uuid']."' ";
|
$sql .= "where domain_uuid = '".$_SESSION['domain_uuid']."' ";
|
||||||
|
|
@ -103,4 +110,4 @@ else {
|
||||||
header("Location: ring_groups.php");
|
header("Location: ring_groups.php");
|
||||||
return;
|
return;
|
||||||
|
|
||||||
?>
|
?>
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue