pari: branch 2.0 r3670 - in /branches/2.0/config: js/astman.js trunks_voip.html

SVN commits to the Asterisk-GUI project asterisk-gui-commits at lists.digium.com
Fri Aug 15 10:24:38 CDT 2008


Author: pari
Date: Fri Aug 15 10:24:38 2008
New Revision: 3670

URL: http://svn.digium.com/view/asterisk-gui?view=rev&rev=3670
Log:

Fix for "Sub: [asterisk-gui] GUI 2.0 Overly Strict SIP Account Name"

> The new Asterisk GUI 2.0 appears to reject SIP account names that are 
> perfectly valid. For example, account names with periods are rejected by 
> the GUI but are perfectly valid within Asterisk.
> 
> This would appear to be an unnecessary restriction, especially since we 
> use a sort of domain name structure for our SIP accounts and have 
> hundreds of client accounts with periods in them :-(
> 
> -- 
> George Pajari (dCAP), netVOICE communications 604 484 VOIP(8647) x102
>   www.netvoice.ca  www.ip-centrex.ca  www.ip-pbx.ca  www.vpas.ca
>    www.digium.ca www.grandstream.ca www.sipura.ca www.snom.ca
> Open Source VoIP/Telephony Specialists  1 877 NET VOIP (638 8647 x102)




Modified:
    branches/2.0/config/js/astman.js
    branches/2.0/config/trunks_voip.html

Modified: branches/2.0/config/js/astman.js
URL: http://svn.digium.com/view/asterisk-gui/branches/2.0/config/js/astman.js?view=diff&rev=3670&r1=3669&r2=3670
==============================================================================
--- branches/2.0/config/js/astman.js (original)
+++ branches/2.0/config/js/astman.js Fri Aug 15 10:24:38 2008
@@ -2345,6 +2345,13 @@
 					}
 					*/
 					break;
+				case 'voipusername':
+					var fb_msg = 'Punctuation and Special Characters are not allowed in this field.' ;
+					if ( /[^a-zA-Z_0-9\.]/.test(x) ){
+						ASTGUI.highlightField( field, fb_msg );
+						return false;
+					}
+					break;
 				default:
 					break;
 			}

Modified: branches/2.0/config/trunks_voip.html
URL: http://svn.digium.com/view/asterisk-gui/branches/2.0/config/trunks_voip.html?view=diff&rev=3670&r1=3669&r2=3670
==============================================================================
--- branches/2.0/config/trunks_voip.html (original)
+++ branches/2.0/config/trunks_voip.html Fri Aug 15 10:24:38 2008
@@ -503,11 +503,9 @@
 	<TR>	<TD align="right">Hostname :</TD>
 		<TD>	<input id='edit_VOIPTrunk_Hostname' size=30 required='yes'></TD>
 	</TR>
-
 	<TR>	<TD align="right">Username :</TD>
-		<TD>	<input id='edit_VOIPTrunk_Username' size=25  required='yes' validation='alphanumericUnd'></TD>
-	</TR>
-
+		<TD>	<input id='edit_VOIPTrunk_Username' size=25  required='yes' validation='voipusername'></TD>
+	</TR>
 	<TR>	<TD align="right">Password :</TD>
 		<TD>	<input id='edit_VOIPTrunk_Password' size=25 required='yes'></TD>
 	</TR>




More information about the asterisk-gui-commits mailing list