[prev in list] [next in list] [prev in thread] [next in thread]
List: asterisk-gui-commits
Subject: rbrindley: branch rbrindley/astman_revamp r4675 -
From: SVN commits to the Asterisk-GUI project
Date: 2009-03-30 14:03:45
Message-ID: E1LoI5Z-0002wt-Sa () wibble ! digium ! internal
[Download RAW message or body]
Author: rbrindley
Date: Mon Mar 30 09:03:42 2009
New Revision: 4675
URL: http://svn.digium.com/svn-view/asterisk-gui?view=rev&rev=4675
Log:
- incoming.js now uss pbx.trunks.rules.remove
Modified:
team/rbrindley/astman_revamp/config/js/incoming.js
Modified: team/rbrindley/astman_revamp/config/js/incoming.js
URL: http://svn.digium.com/svn-view/asterisk-gui/team/rbrindley/astman_revamp/config/js/incoming.js?view=diff&rev=4675&r1=4674&r2=4675
==============================================================================
--- team/rbrindley/astman_revamp/config/js/incoming.js (original)
+++ team/rbrindley/astman_revamp/config/js/incoming.js Mon Mar 30 09:03:42 2009
@@ -101,19 +101,24 @@
var TMP_CONTEXT = ALC.split(STRING_SEPERATOR)[1] ;
var TMP_LINE = ALC.split(STRING_SEPERATOR)[0] ;
- if( TMP_LINE.afterChar('=').beginsWith('s,') ){
- ASTGUI.miscFunctions.delete_LinesLike({ context_name : TMP_CONTEXT, \
beginsWithArr: ['exten=s,'] , filename: 'extensions.conf', cb: \
function(){
- ASTGUI.feedback( { msg: 'deleted Incoming Rule !', showfor: 2 , color: 'blue', \
bgcolor: '#FFFFFF' } );
- window.location.reload();
- }});
- }else{
- var H = new listOfSynActions('extensions.conf') ;
- H.new_action( 'delete', TMP_CONTEXT , TMP_LINE.beforeChar('=') , '' , \
TMP_LINE.afterChar('=') ) ;
- H.callActions();
-
- ASTGUI.feedback( { msg: 'deleted Incoming Rule !', showfor: 2 , color: 'blue', \
bgcolor: '#FFFFFF' } );
- window.location.reload();
- }
+ var resp = top.pbx.trunks.rules.remove({cxt: TMP_CONTEXT, line: TMP_LINE});
+ if (!resp) {
+ ASTGUI.feedback({
+ color: 'red',
+ msg: 'Error removing Calling Rule.',
+ showfor: 2
+ });
+
+ return;
+ }
+
+ ASTGUI.feedback({
+ color: 'green',
+ msg: 'Deleted Incoming Rule.',
+ showfor: 2
+ });
+
+ return;
},
listAllRulesInTable : function(){ // \
incomingRules_MiscFunctions.listAllRulesInTable();
_______________________________________________
--Bandwidth and Colocation Provided by http://www.api-digital.com--
asterisk-gui-commits mailing list
To UNSUBSCRIBE or update options visit:
http://lists.digium.com/mailman/listinfo/asterisk-gui-commits
[prev in list] [next in list] [prev in thread] [next in thread]
Configure |
About |
News |
Add a list |
Sponsored by KoreLogic