mirror of
https://github.com/fusionpbx/fusionpbx.git
synced 2026-01-06 11:43:50 +00:00
Misc: Database class integration.
This commit is contained in:
@@ -88,12 +88,23 @@
|
||||
$this->dialplan_uuid = uuid();
|
||||
}
|
||||
else {
|
||||
//delete the previous details
|
||||
$sql = "delete from v_dialplan_details ";
|
||||
$sql .= "where dialplan_uuid = '".$this->dialplan_uuid."' ";
|
||||
$sql .= "and domain_uuid = '".$this->domain_uuid."' ";
|
||||
$this->db->exec($sql);
|
||||
unset($sql);
|
||||
//build previous details delete array
|
||||
$array['dialplan_details'][0]['dialplan_uuid'] = $this->dialplan_uuid;
|
||||
$array['dialplan_details'][0]['domain_uuid'] = $this->domain_uuid;
|
||||
|
||||
//grant temporary permissions
|
||||
$p = new permissions;
|
||||
$p->add('dialplan_detail_delete', 'temp');
|
||||
|
||||
//execute delete
|
||||
$database = new database;
|
||||
$database->app_name = 'fax';
|
||||
$database->app_uuid = '24108154-4ac3-1db6-1551-4731703a4440';
|
||||
$database->delete($array);
|
||||
unset($array);
|
||||
|
||||
//revoke temporary permissions
|
||||
$p->delete('dialplan_detail_delete', 'temp');
|
||||
}
|
||||
|
||||
//set the fax name
|
||||
@@ -195,4 +206,4 @@ $c->fax_description = $fax_description;
|
||||
$c->dialplan();
|
||||
*/
|
||||
|
||||
?>
|
||||
?>
|
||||
Reference in New Issue
Block a user