Update destinations.php
This commit is contained in:
parent
98f32c27a5
commit
51b7deec86
|
|
@ -299,6 +299,7 @@ class destinations {
|
||||||
break;
|
break;
|
||||||
}
|
}
|
||||||
}
|
}
|
||||||
|
|
||||||
//delete the checked rows
|
//delete the checked rows
|
||||||
if ($action == 'delete') {
|
if ($action == 'delete') {
|
||||||
foreach($destinations as $row) {
|
foreach($destinations as $row) {
|
||||||
|
|
@ -310,16 +311,19 @@ class destinations {
|
||||||
$prep_statement->execute();
|
$prep_statement->execute();
|
||||||
$destinations = $prep_statement->fetchAll(PDO::FETCH_NAMED);
|
$destinations = $prep_statement->fetchAll(PDO::FETCH_NAMED);
|
||||||
$row = $destinations[0];
|
$row = $destinations[0];
|
||||||
|
|
||||||
//delete th dialplan
|
//delete th dialplan
|
||||||
$sql = "delete from v_dialplan_details ";
|
$sql = "delete from v_dialplan_details ";
|
||||||
$sql .= "where dialplan_uuid = '".$row['dialplan_uuid']."';";
|
$sql .= "where dialplan_uuid = '".$row['dialplan_uuid']."';";
|
||||||
$this->db->query($sql);
|
$this->db->query($sql);
|
||||||
unset($sql);
|
unset($sql);
|
||||||
|
|
||||||
//delete th dialplan
|
//delete th dialplan
|
||||||
$sql = "delete from v_dialplans ";
|
$sql = "delete from v_dialplans ";
|
||||||
$sql .= "where dialplan_uuid = '".$row['dialplan_uuid']."';";
|
$sql .= "where dialplan_uuid = '".$row['dialplan_uuid']."';";
|
||||||
$this->db->query($sql);
|
$this->db->query($sql);
|
||||||
unset($sql);
|
unset($sql);
|
||||||
|
|
||||||
//delete the destinations
|
//delete the destinations
|
||||||
$sql = "delete from v_destinations ";
|
$sql = "delete from v_destinations ";
|
||||||
$sql .= "where destination_uuid = '".$row['destination_uuid']."';";
|
$sql .= "where destination_uuid = '".$row['destination_uuid']."';";
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue