Set caller_id_number using sip_from_user if the variable is not set.
This commit is contained in:
parent
76a4e9dd50
commit
af994de554
|
|
@ -299,8 +299,15 @@ if (!class_exists('xml_cdr')) {
|
||||||
if ($duplicate_uuid == false && is_uuid($uuid)) {
|
if ($duplicate_uuid == false && is_uuid($uuid)) {
|
||||||
|
|
||||||
//get the caller ID
|
//get the caller ID
|
||||||
$caller_id_name = urldecode($xml->variables->caller_id_name);
|
if (isset($xml->variables->caller_id_name)) {
|
||||||
$caller_id_number = urldecode($xml->variables->caller_id_number);
|
$caller_id_name = urldecode($xml->variables->caller_id_name);
|
||||||
|
}
|
||||||
|
if (isset($xml->variables->caller_id_number)) {
|
||||||
|
$caller_id_number = urldecode($xml->variables->caller_id_number);
|
||||||
|
}
|
||||||
|
if (!isset($caller_id_number) && isset($xml->variables->sip_from_user)) {
|
||||||
|
$caller_id_number = urldecode($xml->variables->sip_from_user);
|
||||||
|
}
|
||||||
|
|
||||||
//if the origination caller id name and number are set then use them
|
//if the origination caller id name and number are set then use them
|
||||||
if (isset($xml->variables->origination_caller_id_name)) {
|
if (isset($xml->variables->origination_caller_id_name)) {
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue