Add fax destination and update the caller ID.

This commit is contained in:
FusionPBX
2022-04-20 23:05:03 -06:00
committed by GitHub
parent e32c9d1870
commit 48056196bc

View File

@@ -359,6 +359,7 @@
if (caller_id_number ~= nil) then
table.insert(sql, "fax_caller_id_number, ");
end
table.insert(sql, "fax_destination, ");
table.insert(sql, "fax_date, ");
table.insert(sql, "fax_epoch, ");
if (storage_type == "base64") then
@@ -379,6 +380,7 @@
if (caller_id_number ~= nil) then
table.insert(sql, ":caller_id_number, ");
end
table.insert(sql, ":fax_destination, ");
if (database["type"] == "sqlite") then
table.insert(sql, ":fax_date, ");
else
@@ -396,8 +398,9 @@
domain_uuid = domain_uuid;
fax_uuid = fax_uuid;
fax_file = fax_file;
caller_id_name = caller_id_name;
caller_id_number = caller_id_number;
caller_id_name = fax_caller_id_name;
caller_id_number = fax_caller_id_number;
fax_destination = sip_to_user;
fax_base64 = fax_base64;
fax_date = os.date("%Y-%m-%d %X");
fax_time = os.time();
@@ -427,11 +430,12 @@
--freeswitch.consoleLog("INFO","fax_ecm_used: '" .. fax_ecm_used .. "'\n");
freeswitch.consoleLog("INFO","fax_uri: '" .. fax_uri.. "'\n");
if (caller_id_name ~= nil) then
freeswitch.consoleLog("INFO","caller_id_name: " .. caller_id_name .. "\n");
freeswitch.consoleLog("INFO","caller_id_name: " .. fax_caller_id_name .. "\n");
end
if (caller_id_number ~= nil) then
freeswitch.consoleLog("INFO","caller_id_number: " .. caller_id_number .. "\n");
freeswitch.consoleLog("INFO","caller_id_number: " .. fax_caller_id_number .. "\n");
end
freeswitch.consoleLog("INFO","fax_destination: " .. sip_to_user .. "\n");
freeswitch.consoleLog("INFO","fax_result_code: ".. fax_result_code .."\n");
--freeswitch.consoleLog("INFO","mailfrom_address: ".. from_address .."\n");
--freeswitch.consoleLog("INFO","mailto_address: ".. email_address .."\n");