“核心显示应用程序拨号”状态:
g: Proceed with dialplan execution at the next priority in the current
extension if the destination channel hangs up.
因此,将您的代码更改为:
[from-internal-custom]
exten => 80,1,AGI(custom/agi.php)
exten => 80,2,MixMonitor(${FILE}.WAV)
exten => 80,3,Dial(SIP/custom/${NUMBER},,g)
exten => 80,4,deadAGI(custom/finish)
exten => 80,5,Hangup()
如果你想运行你的脚本不管调用者或被调用者挂断:
e: Execute the 'h' extension for peer after the call ends
所以:
[from-internal-custom]
exten => 80,1,AGI(custom/agi.php)
exten => 80,2,MixMonitor(${FILE}.WAV)
exten => 80,3,Dial(SIP/custom/${NUMBER},,ge)
exten => 80,4,deadAGI(custom/finish)
exten => 80,5,Hangup()
exten => h,1,deadAGI(custom/finish)
你的想法几乎没问题。'h' 是扩展名,而不是优先级。