espiceland: branch 2.0 r5141 - /branches/2.0/config/js/pbx2.js

SVN commits to the Asterisk-GUI project asterisk-gui-commits at lists.digium.com
Fri Jan 14 15:13:52 CST 2011


Author: espiceland
Date: Fri Jan 14 15:13:49 2011
New Revision: 5141

URL: http://svnview.digium.com/svn/asterisk-gui?view=rev&rev=5141
Log:
Fixes bug where group = null printed to users.conf for voip trunks.

Modified:
    branches/2.0/config/js/pbx2.js

Modified: branches/2.0/config/js/pbx2.js
URL: http://svnview.digium.com/svn/asterisk-gui/branches/2.0/config/js/pbx2.js?view=diff&rev=5141&r1=5140&r2=5141
==============================================================================
--- branches/2.0/config/js/pbx2.js (original)
+++ branches/2.0/config/js/pbx2.js Fri Jan 14 15:13:49 2011
@@ -1506,7 +1506,6 @@
 	trunk.allow = 'all';
 	trunk.context = ct || '';
 	trunk.disallow = 'all';
-	trunk.group = group || null;
 	trunk.hasexten = 'no';
 	trunk.hasiax = (type === 'iax') ? 'yes' : 'no';
 	trunk.hassip = (type === 'sip') ? 'yes' : 'no';
@@ -1530,7 +1529,9 @@
 		}
 
 		top.sessionData.pbxinfo.trunks[type][name][v] = trunk[v];
-		users_conf.new_action('append', name, v, trunk[v]);
+		if(v != null){
+			users_conf.new_action('append', name, v, trunk[v]);
+		}
 	}
 	top.sessionData.pbxinfo.trunks[type][name]['disallow'] = trunk['disallow'];
 	users_conf.new_action('append', name, 'disallow', trunk['disallow']);
@@ -1552,6 +1553,10 @@
 				group = this.makeDedicatedGroup();
 			}
 		}
+		trunk.group = group;
+	}
+	if(group){
+		users_conf.new_action('append', name, 'group', group);
 	}
 
 	/* TODO: get listOfActions to return a response so we know everythings ok! */




More information about the asterisk-gui-commits mailing list