extension dial certain trunk & internal

Discussion in 'General' started by landfiets, Feb 10, 2009.

  1. landfiets

    Joined:
    May 20, 2008
    Messages:
    20
    Likes Received:
    0
    Hi

    I use Elastix 1.4-2 and want to go deeper in some configuration.
    I want certain extensions to dial out from certain trunks without a prefix.
    So what I did was to make a context in extensions-custom.conf for that trunk.

    [custom-sipgate]
    exten => _XXXX.,1,Set(TRUNK=SIP/1243202)
    exten => _XXXX.,n,Hangup

    So in freepbx I took the certain Extension and filled out in the configuration that extension xxx should use "custom-sipgate" to dial out. So far so good.

    The problem is, that it won't dial internal numbers anymore, since I get the "Adress incomplete" notice.
    I tried several solutions by putting something like exten => _XXX, etc. so for 3 digit numbers it should dial internal but I didnt find the right solution.

    What should I fillout in this custom-sipgate so the extension will use this trunk but also can dialout to internal phones.
    Incoming internal calls are fine. It's only the outgoing calls to other internal phones.

    I only use SIP so no ZAP or something.

    Please help me.
     
  2. pawels

    Joined:
    May 19, 2008
    Messages:
    51
    Likes Received:
    0
    another way ...

    1. In extensions_custom.conf add new context
    [from-XXXX-extension]
    exten => _.,1,GotoIf($[${EXTEN:0:1}=7]?loc:ext)
    exten => _.,n(ext),Goto(from-internal,854${EXTEN},1)
    exten => _.,n(loc),Goto(from-internal,${EXTEN},1)

    TrunkAccessCode for example can be 854
    7 is first digit of extension

    2. For particular extension, context set to from-XXXX-extension

    3. For trunk which have to be chosen create outbound route where dial patterns contain '854|.'
     

Share This Page