espiceland: branch 2.0 r5135 - in /branches/2.0/config/js: astman.js pbx.js
SVN commits to the Asterisk-GUI project
asterisk-gui-commits at lists.digium.com
Wed Dec 15 14:43:14 UTC 2010
Author: espiceland
Date: Wed Dec 15 08:43:09 2010
New Revision: 5135
URL: http://svnview.digium.com/svn/asterisk-gui?view=rev&rev=5135
Log:
Add back the local-callingrule-cid macro which was accidentally deleted.
Modified:
branches/2.0/config/js/astman.js
branches/2.0/config/js/pbx.js
Modified: branches/2.0/config/js/astman.js
URL: http://svnview.digium.com/svn/asterisk-gui/branches/2.0/config/js/astman.js?view=diff&rev=5135&r1=5134&r2=5135
==============================================================================
--- branches/2.0/config/js/astman.js (original)
+++ branches/2.0/config/js/astman.js Wed Dec 15 08:43:09 2010
@@ -359,6 +359,7 @@
contexts: {
guitools : 'asterisk_guitools', // gui tools context
dialtrunks : 'trunkdial-failover-0.3', // trunkdial macro with failback trunk and setcid, ASTGUI.contexts.dialtrunks
+ localcrcid: 'local-callingrule-cid-0.1', // setcid for local calling rules, ASTGUI.contexts.localcrcid
subscribe : 'device-hints', //subscribecontext for sip.conf (aka devicestate fun)
CONFERENCES : 'conferences', // ASTGUI.contexts.CONFERENCES
QUEUES : 'queues', //ASTGUI.contexts.QUEUES
@@ -2055,6 +2056,9 @@
if(macroargs.length == 4 || macroargs.length == 6){
cr.callerID = macroargs[macroargs.length - 1];
}
+ }else if( str.contains('local-callingrule') ){ // if is some version of localcrcid macro
+ cr.destination = "Goto(" + macroargs[1] + ',' + macroargs[2] + ',' + macroargs[3] + ')';
+ cr.callerID = macroargs[4] ? macroargs[4] : '';
}
}else{
cr.destination = ASTGUI.parseContextLine.getAppWithArgs( str ) ;
Modified: branches/2.0/config/js/pbx.js
URL: http://svnview.digium.com/svn/asterisk-gui/branches/2.0/config/js/pbx.js?view=diff&rev=5135&r1=5134&r2=5135
==============================================================================
--- branches/2.0/config/js/pbx.js (original)
+++ branches/2.0/config/js/pbx.js Wed Dec 15 08:43:09 2010
@@ -93,6 +93,10 @@
check_For_Contexts[ASTGUI.contexts.guitools][4] = 'exten=record_vmenu,n,Record(${var1},0,500,k)';
}
+ check_For_Contexts[ 'macro-' + ASTGUI.contexts.localcrcid ] = [
+ 'exten=s,1,Set(CALLERID(all)=${IF($[${LEN(${ARG4})} > 2]?${ARG4}:)})',
+ 'exten=s,n,Goto(${ARG1},${ARG2},${ARG3})'
+ ];
check_For_Contexts[ 'macro-' + ASTGUI.contexts.dialtrunks ] = [
// "; Macro by = Brandon Kruse, Matthew O'Gorman, & Erin Spiceland <espiceland at digium.com>",
'exten=s,1,GotoIf($[${LEN(${FMCIDNUM})} > 6]?1-fmsetcid,1)',
More information about the asterisk-gui-commits
mailing list