All pastes #2621 Raw Edit

Anonymous

public ini v1 · immutable
#2621 ·published 2004-12-03 18:32 UTC
rendered paste body
; PRI dialing macro; I want to track who's calling through the PRI.  If $ACCOUNTCODE is not set, set it to $ARG2.; If $ARG2 is empty, default to the string "benshaw".  This way the upstream dialplan can; override the account code, or it can be set explicitly though this macro but no matter what; it will never be blank.[macro-pri-dial]exten => s,1,GotoIf($[$ACCOUNTCODE != ""],s,gotac)exten => s,n,SetVar(ACCOUNTCODE=${ARG2})exten => s,n,GotoIf($[{$ARG2} != ""],s,gotac)exten => s,n,SetVar(ACCOUNTCODE=benshaw)exten => s,n(gotac),SetAccount(${ACCOUNTCODE})exten => s,n,Dial(${BELLTRUNK}/${ARG1})exten => s,n,Wait(5)exten => s,n,Congestionexten => s,n(dial+101),Busy