markster: trunk r20 - in /trunk/config: numberplan.html trunks.html users.html

asterisk-gui-commits at lists.digium.internal asterisk-gui-commits at lists.digium.internal
Sat Sep 9 23:17:55 CDT 2006


Author: markster
Date: Sat Sep  9 23:17:54 2006
New Revision: 20

URL: http://svn.digium.com/view/asterisk-gui?rev=3D20&view=3Drev
Log:
More numberplan/users/trunk work

Modified:
    trunk/config/numberplan.html
    trunk/config/trunks.html
    trunk/config/users.html

Modified: trunk/config/numberplan.html
URL: http://svn.digium.com/view/asterisk-gui/trunk/config/numberplan.html?r=
ev=3D20&r1=3D19&r2=3D20&view=3Ddiff
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D
--- trunk/config/numberplan.html (original)
+++ trunk/config/numberplan.html Sat Sep  9 23:17:54 2006
@@ -49,7 +49,7 @@
 		// Called when (new/existing) Pattern is Saved - Onclik of "Save" of Pat=
tern
 		var flags =3D "d";
 		var xargs=3D"";
-		var room =3D '${EXTEN:1}';
+		var room;
 		var newpriority =3D 0 ;
 		// Calculate New Priority
 		if( $('priority').value !=3D ''){
@@ -68,7 +68,10 @@
 				=

 				newpriority =3D Number(newpriority) + 1;
 		}
-		return $('name').value + "," + newpriority + ",Macro(trunkdial,${" + $('=
trunk').value + "}/" + room + ")";
+		room =3D $('trunk').stored_config.catbyname[$('trunk').value].fieldbynam=
e['dialformat'];
+		if (!room || (room =3D=3D ''))
+ 			room =3D '${EXTEN:1}';
+ 		return $('name').value + "," + newpriority + ",Macro(trunkdial,${" + $(=
'trunk').value + "}/" + room + ")";
 	}
 =

 =


Modified: trunk/config/trunks.html
URL: http://svn.digium.com/view/asterisk-gui/trunk/config/trunks.html?rev=
=3D20&r1=3D19&r2=3D20&view=3Ddiff
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D
--- trunk/config/trunks.html (original)
+++ trunk/config/trunks.html Sat Sep  9 23:17:54 2006
@@ -36,7 +36,8 @@
 	var fieldnames =3D new Array(
 				'delete', 'status', 'new', 'save', 'cancel','secret', 'provider', 'zap=
chan',
 				'trunkstyleanalog','trunkstylevoip', 'name', 'username', 'trunkname', =
'callerid',
-				'hasexten', 'hassip', 'hasiax');
+				'hasexten', 'hassip', 'hasiax','registeriax','registersip','host','dia=
lformat','context','group'
+				);
 				=

 	var provfieldnames =3D new Array('providerdesc', 'providerlogo');
 =

@@ -121,10 +122,16 @@
 			$('trunkname').value =3D $('provider').options[$('provider').selectedIn=
dex].innerHTML + " - " + $('username').value;
 			$('hassip').value =3D provider.fieldbyname['hassip'];
 			$('hasiax').value =3D provider.fieldbyname['hasiax'];
+			$('registeriax').value =3D provider.fieldbyname['registeriax'];
+			$('registersip').value =3D provider.fieldbyname['registersip'];
+			$('host').value =3D provider.fieldbyname['host'];
+			$('dialformat').value =3D provider.fieldbyname['dialformat'];
 			$('callerid').value =3D '';
+			$('context').value =3D 'default';
 			for (var x=3D0;x<$('zapchan').options.length;x++)
 				$('zapchan').options[x].selected =3D false;
 			$('zapchan').value =3D '';
+			$('group').value =3D '';
 		} else if ($('trunkstyleanalog').checked) {
 			if (!$('zapchan').value) {
 				alert("When using Analog, at least one port must be selected.");
@@ -149,6 +156,7 @@
 			$('hassip').value =3D 'no';
 			$('hasiax').value =3D 'no';
 			$('callerid').value =3D 'asreceived';
+			$('group').value =3D box.value.split('_')[1];
 		} else {
 			alert("A trunk must be either Analog or VoIP.");
 			return true;
@@ -245,6 +253,12 @@
 				<input type=3D'hidden' id=3D'hassip'>
 				<input type=3D'hidden' id=3D'hasexten'>
 				<input type=3D'hidden' id=3D'callerid'>
+				<input type=3D'hidden' id=3D'registeriax'>
+				<input type=3D'hidden' id=3D'registersip'>
+				<input type=3D'hidden' id=3D'host'>
+				<input type=3D'hidden' id=3D'dialformat'>
+				<input type=3D'hidden' id=3D'context'>
+				<input type=3D'hidden' id=3D'group'>
 				<div id=3D'analogvoipcontainer' style=3D'height:450;overflow:hidden'>
 				<div id=3D'analog' style=3D'height:0;overflow:hidden'>
 				<table>

Modified: trunk/config/users.html
URL: http://svn.digium.com/view/asterisk-gui/trunk/config/users.html?rev=3D=
20&r1=3D19&r2=3D20&view=3Ddiff
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=3D=
=3D=3D=3D
--- trunk/config/users.html (original)
+++ trunk/config/users.html Sat Sep  9 23:17:54 2006
@@ -35,7 +35,7 @@
 	var numcallbacks =3D new Object;
 	var fieldnames =3D new Array(
 				'delete', 'status', 'new', 'save', 'cancel','name','fullname','secret'=
,'email','number','zapchan','context',
-				'hasvoicemail','hasdirectory','hassip','hasiax','hasmanager','callwait=
ing','threewaycalling','mailbox','isagent');
+				'hasvoicemail','hasdirectory','hassip','hasiax','hasmanager','callwait=
ing','threewaycalling','mailbox','isagent','group');
 =

 	extencallbacks.format =3D function(t, x) {
 		if ((t.name !=3D specialcontext))
@@ -70,6 +70,7 @@
 	}
 	callbacks.checkparams =3D function(box) {
 		$('mailbox').value =3D $('name').value;
+		$('group').value =3D '';
 		return false;
 	}
 	callbacks.newcategory =3D function() {
@@ -174,7 +175,7 @@
 				<tr><td>Analog Phone:</td><td><select size=3D"1" id=3D'zapchan' style=
=3D'width:120px'></select></td></tr>
 				<tr><td>Number Plan:</td><td><select size=3D'1' id=3D'context' style=
=3D'width:120px'></select></td></tr>
 				<tr><td colspan=3D'2' align=3D'center'><div style=3D"height:15px" id=
=3D'status'></div></td></tr>
-				<tr><td colspan=3D'2' align=3D'center'><input type=3D'hidden' id=3D'ma=
ilbox'></td></tr>
+				<tr><td colspan=3D'2' align=3D'center'><input type=3D'hidden' id=3D'ma=
ilbox'><input type=3D'hidden' id=3D'group'></td></tr>
 				</table>
 			</td>
 			</tr>



More information about the asterisk-gui-commits mailing list