On Thu, Apr 5, 2012 at 10:52 AM, John Kiniston <johnkinis...@gmail.com>wrote:

>
>
> On Thu, Apr 5, 2012 at 10:35 AM, <list...@gmail.com> wrote:
>
>>
>> If I wanted to route a call from a particular DID and the CALLERID from a
>> specific A/C this doesn't seem to work for me:
>>
>> exten => 6140000000/_702XXXXXXX,n,Goto(context1,s,1)
>> exten => 6140000000/6149999999,n,Goto(context2,s,1)
>> exten => 6140000000/6149999998,n,Goto(context3,s,1)
>> exten => 6140000000/6149999997,n,Dial(SIP/7777,25)
>>
>>
> You are pretty close, I  think it's your priorities that are the problem.
> When I use "Ex Girl Friend Logic" I write my extensions this way:
>
> exten => 6140000000/6149999999,1,Goto(context2,s,1)
> exten => 6140000000/6149999998,1,Goto(context3,s,1)
> exten => 6140000000,1,Dial(SIP/7777,25)
>
>
I agree, priorities are very tricky in this case, and I've spent a lot of
time figuring out similar scenarios.  Also you may need to use an 's'
priority in some cases, where there are two potential matches that are the
same priority.  I'm sorry I can't think of where I have a useful code
snippet for your exact case.  I'd recommend starting with a fully working
explicit statement then work back from there to less explicit:

exten => 16027170050/8774613644,1,Goto(monkeys,s,1)

Then:

exten => 1602717005X/8774613644,1,Goto(monkeys,s,1)

Etc.

-- 
Carlos Alvarez
TelEvolve
602-889-3003
--
_____________________________________________________________________
-- Bandwidth and Colocation Provided by http://www.api-digital.com --
New to Asterisk? Join us for a live introductory webinar every Thurs:
               http://www.asterisk.org/hello

asterisk-users mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-users

Reply via email to