mirror of
https://github.com/fusionpbx/fusionpbx.git
synced 2025-12-30 00:53:50 +00:00
Update blf_subscribe.lua (#6482)
This commit is contained in:
@@ -7,6 +7,9 @@ else
|
||||
service_name = proto
|
||||
end
|
||||
|
||||
--make sure the scripts/run dir exists
|
||||
mkdir(scripts_dir .. "/run");
|
||||
|
||||
require "resources.functions.config"
|
||||
require "resources.functions.split"
|
||||
require "resources.functions.trim";
|
||||
@@ -22,7 +25,9 @@ local find_voicemail do
|
||||
from v_voicemail_messages t1
|
||||
inner join v_domains t2 on t1.domain_uuid = t2.domain_uuid
|
||||
inner join v_voicemails t3 on t1.voicemail_uuid = t3.voicemail_uuid
|
||||
where t2.domain_name = :domain_name and t3.voicemail_id = :extension and t1.message_status != 'saved']]
|
||||
where t2.domain_name = :domain_name
|
||||
and t3.voicemail_id = :extension
|
||||
and (t1.message_status is null or message_status = '')]]
|
||||
|
||||
function find_voicemail(user)
|
||||
local ext, domain_name = split_first(user, '@', true)
|
||||
|
||||
Reference in New Issue
Block a user