remove origination_callee_id_name from domain-variables dialplan

Removed for these reasons.
- Update the caller's display when making a call to the final destination number rather than the number that was called.
- It also modifies the phone history of called numbers
- Changes the number in Call Detail Records  to the final destination rather than Caller's Destination
This commit is contained in:
FusionPBX
2023-07-29 12:55:52 -06:00
committed by GitHub
parent 8b502d4355
commit 5e04c63824

View File

@@ -124,6 +124,30 @@
}
//remove origination_callee_id_name from domain-variables dialplan
if ($domains_processed == 1) {
$sql = "select count(*) from v_dialplans ";
$sql .= "where dialplan_name = 'domain-variables' ";
$sql .= "and dialplan_xml like '%origination_callee_id_name%' ";
$database = new database;
$num_rows = $database->select($sql, null, 'column');
if ($num_rows > 0) {
$sql = "delete from v_dialplan_details \n";
$sql .= "where dialplan_uuid in (select dialplan_uuid from v_dialplans where dialplan_name = 'domain-variables' or dialplan_name = 'variables') \n";
$sql .= "and dialplan_detail_data like 'origination_callee_id_name%'; \n";
$database->execute($sql);
$sql = "update v_dialplans set dialplan_xml = REPLACE(dialplan_xml, '<action application=\"export\" data=\"origination_callee_id_name=\${destination_number}\"/>', ''), update_date = now() \n";
$sql .= "where dialplan_uuid in (select dialplan_uuid from v_dialplans where dialplan_name = 'domain-variables' or dialplan_name = 'variables'); \n";
$database->execute($sql);
$sql = "update v_dialplans set dialplan_xml = REPLACE(dialplan_xml, '<action application=\"export\" data=\"origination_callee_id_name=\${destination_number}\" inline=\"true\"/>', ''), update_date = now() \n";
$sql .= "where dialplan_uuid in (select dialplan_uuid from v_dialplans where dialplan_name = 'domain-variables' or dialplan_name = 'variables'); \n";
$database->execute($sql);
}
unset($sql, $num_rows);
}
//add not found dialplan to inbound routes
/*
if ($domains_processed == 1) {