Problems with phones sending outside calls to voicemail


#1

I have a problem with my Asterisk system sending outside calls to individual users voicemail instead of sending users to the auto-attendant. It happens if a user is on both lines their phone supports. When this happens the next incoming call is sent directly to their voicemail instead of ringing other phones. Below is my extensions.conf, any thoughts?

[general]
static=yes
writeprotect=no
autofallthrough=yes
clearglobalvars=no

[globals]
ALL=Sip/110&Sip/111&Sip/112&Sip/113&Sip/115&Sip/116&Zap/1&Zap/2&Zap/3&Zap/4

[default]
exten => 110,1,Macro(extensions,Sip/110,110)
exten => 111,1,Macro(extensions,Sip/111,111)
exten => 112,1,Macro(extensions,Sip/112,112)
exten => 113,1,Macro(extensions,Sip/113,113)
exten => 114,1,Macro(extensions,Zap/114,114)
exten => 115,1,Macro(extensions,Sip/115,115)
exten => 116,1,Macro(extensions,Sip/116,116)
exten => 117,1,Macro(extensions,Zap/117,117)
exten => 120,1,Macro(extensions,Zap/120,120)
exten => 121,1,Macro(extensions,Zap/121,121)

[incoming]
; Weekend Hours Check
exten => s,1,GotoIfTime(17:01-23:59|fri||?weekend,s,1)
exten => s,2,GotoIfTime(|sat||?weekend,s,1)
exten => s,3,GotoIfTime(
|sun||?weekend,s,1)
exten => s,4,GotoIfTime(0:01-8:59|mon||?weekend,s,1)

; Busines Hours Check
exten => s,5,GotoIfTime(9:00-17:00|mon-fri||?daytime,s,1)

; Evening Hours Check
exten => s,6,Goto(evening,s,1)

[daytime]
exten => s,1,Dial(${ALL}|18)
exten => s,2,Wait,1
exten => s,3,Background(NSR-Daytime)
exten => s,4,Wait,5
exten => s,5,Goto(daytime,s,3)

exten => 0,1,Voicemail(u100)
exten => 1,1,Voicemail(u101)
exten => 2,1,Directory(default)

exten => 110,1,Goto(internal,110,1)
exten => 111,1,Goto(internal,111,1)
exten => 112,1,Goto(internal,112,1)
exten => 113,1,Goto(internal,113,1)
exten => 114,1,Goto(internal,114,1)
exten => 115,1,Goto(internal,115,1)
exten => 116,1,Goto(internal,116,1)
exten => 117,1,Goto(internal,117,1)
exten => 120,1,Goto(internal,120,1)
exten => 121,1,Goto(internal,121,1)

[evening]
exten => s,1,Answer
exten => s,2,Wait,1
exten => s,3,Background(NSR-Evening)
exten => s,4,Wait,5
exten => s,5,Goto(evening,s,3)

exten => 0,1,Voicemail(u100)
exten => 1,1,Voicemail(u101)
exten => 2,1,Directory(default)

exten => 110,1,Goto(internal,110,1)
exten => 111,1,Goto(internal,111,1)
exten => 112,1,Goto(internal,112,1)
exten => 113,1,Goto(internal,113,1)
exten => 114,1,Goto(internal,114,1)
exten => 115,1,Goto(internal,115,1)
exten => 116,1,Goto(internal,116,1)
exten => 117,1,Goto(internal,117,1)
exten => 120,1,Goto(internal,120,1)
exten => 121,1,Goto(internal,121,1)

[weekend]
exten => s,1,Answer
exten => s,2,Wait,1
exten => s,3,Background(NSR-Weekend)
exten => s,4,Wait,5
exten => s,5,Goto(weekend,s,3)

exten => 0,1,Background(transfer)
exten => 0,2,Voicemail(u100)
exten => 1,1,Background(transfer)
exten => 1,2,Voicemail(u101)
exten => 2,1,Background(transfer)
exten => 2,2,Directory(default)

exten => 110,1,Goto(internal,110,1)
exten => 111,1,Goto(internal,111,1)
exten => 112,1,Goto(internal,112,1)
exten => 113,1,Goto(internal,113,1)
exten => 114,1,Goto(internal,114,1)
exten => 115,1,Goto(internal,115,1)
exten => 116,1,Goto(internal,116,1)
exten => 117,1,Goto(internal,117,1)
exten => 120,1,Goto(internal,120,1)
exten => 121,1,Goto(internal,121,1)

[internal]
include => outgoing
include => parkedcalls
exten => 110,1,Macro(extensions,Sip/110,110)
exten => 111,1,Macro(extensions,Sip/111,111)
exten => 112,1,Macro(extensions,Sip/112,112)
exten => 113,1,Macro(extensions,Sip/113,113)
exten => 114,1,Macro(extensions,Zap/4,114)
exten => 115,1,Macro(extensions,Sip/115,115)
exten => 116,1,Macro(extensions,Sip/116,116)
exten => 117,1,Macro(extensions,Zap/1,114)
exten => 120,1,Macro(extensions,Zap/2,114)
exten => 121,1,Macro(extensions,Zap/3,114)

exten => 150,1,VoicemailMain
exten => 151,1,VoicemailMain(s${CALLERIDNUM})
exten => _31XX,1,Voicemail(u${EXTEN:1})

exten => 155,1,Authenticate(5309)
exten => 155,2,Goto(recordings,s,1)

[recordings]
exten => s,1,Background(NSR-Recordings-Main)
exten => s,2,Wait,5
exten => s,3,Goto(recordings,s,1)
exten => a,1,Hangup

Record the different NSR greetings.

exten => 1,1,Background(NSR-Recordings-Inst)
exten => 1,2,Record(NSR-Daytime:wav|4)
exten => 1,3,Goto(recordings,s,1)
exten => 2,1,Background(NSR-Daytime)
exten => 2,2,Goto(recordings,s,1)

exten => 4,1,Background(NSR-Recordings-Inst)
exten => 4,2,Record(NSR-Evening:wav|4)
exten => 4,3,Goto(recordings,s,1)
exten => 5,1,Background(NSR-Evening)
exten => 5,2,Goto(recordings,s,1)

exten => 7,1,Background(NSR-Recordings-Inst)
exten => 7,2,Record(NSR-Weekend:wav|4)
exten => 7,3,Goto(recordings,s,1)
exten => 8,1,Background(NSR-Weekend)
exten => 8,2,Goto(recordings,s,1)

exten => 0,1,Background(NSR-Recordings-Inst)
exten => 0,2,Record(NSR-Recordings-Main:wav|4)
exten => 0,3,Goto(recordings,s,1)

[macro-extensions]
exten => s,1,Dial(${ARG1}|20)
exten => s,2,Voicemail(u${ARG2})
exten => s,102,Voicemail(b${ARG2})

[outgoing]
exten => _X.,1,Dial(Zap/g1/${EXTEN})