VoIP Mailing List Archives
Mailing list archives for the VoIP community |
|
View previous topic :: View next topic |
Author |
Message |
ronramos1004 at yahoo.com Guest
|
Posted: Thu Apr 24, 2008 8:57 pm Post subject: [asterisk-users] followme scenarios |
|
|
Hi All,
I'm tryng to test different scenarios for followme for different users:
[localext]
exten => 101,1,Set(FM = "ALWAYS");
exten => 101,n,Macro(dial-ext|SIP/${EXTEN}|vm-10000|moh-101|fm-101);
exten => 101,n,Hangup
exten => 102,1,Set(FM = "NEVER");
exten => 102,n,Macro(dial-ext|SIP/${EXTEN}|vm-10000|moh-102|fm-102);
exten => 102,n,Hangup
exten => 103,1,Set(FM = "WHENBUSY");
exten => 103,n,Macro(dial-ext|SIP/${EXTEN}|vm-10000|moh-103|fm-103);
exten => 103,n,Hangup
exten => 104,1,Set(FM = "WHENUNAVAILABLE");
exten => 104,n,Macro(dial-ext|SIP/${EXTEN}|vm-10000|moh-103|fm-103);
exten => 104,n,Hangup
exten => 105,1,Set(FM = "CUSTOM");
exten => 105,n,Macro(dial-ext|SIP/${EXTEN}|vm-10000|moh-103|fm-103);
exten => 105,n,Hangup
[macro-dial-ext]
exten => s,1,SetMusicOnHold(${ARG3})
exten => s,n,Dial(${ARG1},5,M(setmusiconhold,${ARG3}))
exten => s,n,GotoIf(FM = "NEVER"|?vm)
exten => s,n,GotoIf(FM = "CUSTOM"|?s-CUSTOM,1)
exten => s,n,GotoIf(FM = "WHENUNAVAILABLE"|?s-CHANUNAVAIL)
exten => s,n,GotoIf(FM = "WHENBUSY"|?s-BUSY)
exten => s-CHANUNAVAIL,1,Followme(${ARG4})
exten => s-BUSY,1,Followme(${ARG4})
exten => s-CUSTOM,1,GotoIftime(17:00-19:00|*|*|*?c-CUSTOM,n)
exten => s-CUSTOM,n,Followme(${ARG4})
exten => s,n,Followme(${ARG4})
exten => s,n(vm),Voicemail(${MACRO_EXTEN}@${ARG2}|u)
exten => s,n,Playback(vm-goodbye)
exten => s,n,Hangup
but it just keeps on going to this line
exten => s,n,GotoIf(FM = "NEVER"|?vm)
ami using GotoIf correctly? or am i referring to the FM variable properly? and is there easier way of doing this? TIA
regards
Ron
---------------------------------
Be a better friend, newshound, and know-it-all with Yahoo! Mobile. Try it now.
-------------- next part --------------
An HTML attachment was scrubbed...
URL: http://lists.digium.com/pipermail/asterisk-users/attachments/20080424/50fbd2e3/attachment.htm |
|
Back to top |
|
|
jsmith at digium.com Guest
|
Posted: Fri Apr 25, 2008 9:16 am Post subject: [asterisk-users] followme scenarios |
|
|
On Thu, 2008-04-24 at 18:57 -0700, ronald ramos wrote:
Quote: | ami using GotoIf correctly?
|
No, you're not using GotoIf() correctly. In fact, there are several
problems with your syntax. The first problem I spot is that the
GotoIf() application requires an expression, and you haven't supplied an
expression. Expressions in Asterisk are easy to spot, as they're
enclosed in $[ ]. You also need to put ${ } around your variables when
you're trying to retrieve their value, and you've got an errant pipe in
the line as well.
Replace all the lines that look like:
GotoIf(FM = "NEVER"|?vm)
with this syntax:
GotoIf($["${FM}" = "NEVER"]?vm)
--
Jared Smith
Community Relations Manager
Digium, Inc. |
|
Back to top |
|
|
|
|
|
You cannot post new topics in this forum You cannot reply to topics in this forum You cannot edit your posts in this forum You cannot delete your posts in this forum You cannot vote in polls in this forum
|
Powered by phpBB © 2001, 2005 phpBB Group
|