[Asterisk-Users] Dial Plan Logic Problem
Jon Farmer
viperdude_uk at yahoo.co.uk
Wed Apr 5 03:18:21 MST 2006
Hi
I can't for the life of me work out why this is not
working. When in the campon contect if you hit a DTMF
key 2 you get moved to the exten => 2 defined in the
mainmenu context not the exten => 2 defined in the
campon context. What is wrong? The same happens if you
hit key 1.
[campon]
exten => _*1XXX,1,Answer
exten => _*1XXX,2,SetCallerID(${CALLERIDNUM})
exten => _*1XXX,3,SetVar(CALLEDEXTEN=${EXTEN:2,3})
exten => _*1XXX,4,ResponseTimeout(3)
exten => _*1XXX,5,Background(entagroup/campon)
exten => _*1XXX,6,SetVar(LOOPER=1)
exten => _*1XXX,7,Background(entagroup/silence)
exten => _*1XXX,8,NoOp()
exten => _*1XXX,9,GotoIf($[${LOOPER} < 10]?10:13)
exten => _*1XXX,10,Dial(Local/${CALLEDEXTEN},5,trm)
exten => _*1XXX,11,SetVar(LOOPER=$[${LOOPER} + 1])
exten => _*1XXX,12,Goto(9)
exten => _*1XXX,13,Goto(4)
exten => _*1XXX,14,Hangup
exten => 1,1,VoiceMail(b${CALLEDEXTEN})
exten => 1,2,Hangup
exten => 2,1,SetCallerID("Camped on ${CALLEDEXTEN}")
exten => 2,2,Goto(huntgroups,101,1)
exten => 2,3,Hangup
[mainmenu]
exten => s,1,Set(LOOPER=1)
exten => s,2,ResponseTimeout(6)
exten => s,3,Background(entagroup/mainmenu)
exten => s,4,Background(entagroup/silence)
exten => s,5,Set(LOOPER=$[${LOOPER} + 1])
exten => s,6,GotoIf($[${LOOPER} < 4]?mainmenu,s,2)
exten => s,7,Goto(huntgroups,0,1)
exten => t,1,GotoIf($[${LOOPER} < 4]?mainmenu,s,2)
exten => t,2,Hangup
exten => i,1,Goto(mainmenu,s,1)
exten => 1,1,Goto(sales,s,1)
exten => 2,1,Goto(finance,s,1)
exten => 0,1,Goto(huntgroups,0,1)
exten => #,1,Goto(mainmenu,s,1)
Jon Farmer
Telford, Shropshire, UK
___________________________________________________________
Yahoo! Messenger - NEW crystal clear PC to PC calling worldwide with voicemail http://uk.messenger.yahoo.com
More information about the asterisk-users
mailing list