From 54e918ea7562fb852724ea9fbd16f2f1dbdaba62 Mon Sep 17 00:00:00 2001 From: Mark Crane Date: Fri, 25 Apr 2014 05:52:00 +0000 Subject: [PATCH] Fix the dialplan destination delete and reactivate the transaction support --- app/destinations/destination_delete.php | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) diff --git a/app/destinations/destination_delete.php b/app/destinations/destination_delete.php index 30051f37a1..56e4c7d5a9 100644 --- a/app/destinations/destination_delete.php +++ b/app/destinations/destination_delete.php @@ -63,22 +63,22 @@ else { unset ($prep_statement); //start the atomic transaction - //$db->beginTransaction(); + $db->beginTransaction(); //delete the dialplan if (isset($dialplan_uuid)) { $sql = "delete from v_dialplan_details "; $sql .= "where domain_uuid = '$domain_uuid' "; - $sql .= "and dialplan_uuid = '$id' "; + $sql .= "and dialplan_uuid = '$dialplan_uuid' "; $db->exec(check_sql($sql)); unset($sql); - $sql = "delete from v_dialplan "; + $sql = "delete from v_dialplans "; $sql .= "where domain_uuid = '$domain_uuid' "; - $sql .= "and dialplan_uuid = '$id' "; + $sql .= "and dialplan_uuid = '$dialplan_uuid' "; $db->exec(check_sql($sql)); unset($sql); - } + } //delete the destination $sql = "delete from v_destinations "; @@ -88,7 +88,7 @@ else { unset($sql); //commit the atomic transaction - //$db->commit(); + $db->commit(); //synchronize the xml config save_dialplan_xml();