I am having a special requests about ring groups (when a call comes in, multiple SIP phones ring simultaniously), so I need to use the Local channel for implementation of the dialplan. This is the code:
[interal_calls]
exten => 1100,1,Dial(Local/1101@interal_calls&Local/1103@interal_calls,40,t)
exten => 1100,n,Hangup()
;*** Peers that ring - in case nobody answers the call, the missed call is not listed on the phone ***
exten => 1101,1,Dial(SIP/2&SIP/3,40,tc)
exten => 1101,n,Hangup()
;*** Peers that ring - in case nobody answers the call, the missed call is listed on the phone ***
exten => 1103,1,SIPAddHeader(Alert-Info: info=<Bellcore-dr5>)
exten => 1103,n,Dial(SIP/1,40,t)
exten => 1103,n,Hangup()
The code works as expected in case of unanswered call. Because of the Dial “c” flag, the missed call is listed only on phone 1. The problem is if the call is answered on phones 2 and 3 - the phone 1 lists a missed call in this case. This is very wrong.
The reason for this is that the Reason header is not sent in SIP Cancel to phone 1 in case when phone 2 or phone 3 answer the call.
Is this a bug in Asterisk or can I correct the Dialplan in any way to fix this problem?
I tried using the /n on the end of the Local channel with little success.