Restore sip_from_user and 2 lines for continue to directory.lua.
This commit is contained in:
parent
30b6c8990c
commit
765d34668c
|
|
@ -197,8 +197,10 @@
|
||||||
if (debug["sql"]) then
|
if (debug["sql"]) then
|
||||||
freeswitch.consoleLog("notice", "[xml_handler] SQL: " .. sql .. "\n");
|
freeswitch.consoleLog("notice", "[xml_handler] SQL: " .. sql .. "\n");
|
||||||
end
|
end
|
||||||
|
continue = false;
|
||||||
dbh:query(sql, function(row)
|
dbh:query(sql, function(row)
|
||||||
--general
|
--general
|
||||||
|
continue = true;
|
||||||
domain_uuid = row.domain_uuid;
|
domain_uuid = row.domain_uuid;
|
||||||
extension_uuid = row.extension_uuid;
|
extension_uuid = row.extension_uuid;
|
||||||
extension = row.extension;
|
extension = row.extension;
|
||||||
|
|
@ -216,6 +218,7 @@
|
||||||
auth_acl = row.auth_acl;
|
auth_acl = row.auth_acl;
|
||||||
--variables
|
--variables
|
||||||
sip_from_user = row.extension;
|
sip_from_user = row.extension;
|
||||||
|
sip_from_number = (#number_alias > 0) and number_alias or row.extension;
|
||||||
call_group = row.call_group;
|
call_group = row.call_group;
|
||||||
call_screen_enabled = row.call_screen_enabled;
|
call_screen_enabled = row.call_screen_enabled;
|
||||||
user_record = row.user_record;
|
user_record = row.user_record;
|
||||||
|
|
@ -372,7 +375,7 @@
|
||||||
table.insert(xml, [[ <variable name="extension_uuid" value="]] .. extension_uuid .. [["/>]]);
|
table.insert(xml, [[ <variable name="extension_uuid" value="]] .. extension_uuid .. [["/>]]);
|
||||||
table.insert(xml, [[ <variable name="call_timeout" value="]] .. call_timeout .. [["/>]]);
|
table.insert(xml, [[ <variable name="call_timeout" value="]] .. call_timeout .. [["/>]]);
|
||||||
table.insert(xml, [[ <variable name="caller_id_name" value="]] .. sip_from_user .. [["/>]]);
|
table.insert(xml, [[ <variable name="caller_id_name" value="]] .. sip_from_user .. [["/>]]);
|
||||||
table.insert(xml, [[ <variable name="caller_id_number" value="]] .. sip_from_user .. [["/>]]);
|
table.insert(xml, [[ <variable name="caller_id_number" value="]] .. sip_from_number .. [["/>]]);
|
||||||
if (string.len(call_group) > 0) then
|
if (string.len(call_group) > 0) then
|
||||||
table.insert(xml, [[ <variable name="call_group" value="]] .. call_group .. [["/>]]);
|
table.insert(xml, [[ <variable name="call_group" value="]] .. call_group .. [["/>]]);
|
||||||
end
|
end
|
||||||
|
|
|
||||||
Loading…
Reference in New Issue