[asterisk-gui] pari: trunk r1201 - in /trunk/config: ./ images/ scripts/ setup/

Pari Nannapaneni pari at digium.com
Tue Jul 3 15:01:13 CDT 2007


added back in 1203 ;)

thanks
-Pari



----- Original Message -----
From: "bkruse" <bkruse at digium.com>
To: asterisk-gui at lists.digium.com
Sent: Tuesday, July 3, 2007 2:05:20 PM (GMT-0600) America/Chicago
Subject: Re: [asterisk-gui] pari: trunk r1201 - in /trunk/config: ./ images/ scripts/ setup/

Pari, the astman.js fix for the callbacks is for the active channels page.

It was fixed, dont revert that particular part.

-bk


SVN commits to the Asterisk-GUI project wrote:
> Author: pari
> Date: Tue Jul  3 14:05:14 2007
> New Revision: 1201
>
> URL: http://svn.digium.com/view/asterisk-gui?view=rev&rev=1201
> Log:
> reverting changes done by bkruse in the last few commits for supporting bandwidth.com
>
> Removed:
>     trunk/config/images/bandwidth.gif
> Modified:
>     trunk/config/scripts/astman.js
>     trunk/config/setup/1.html
>     trunk/config/trunks.html
>
> Modified: trunk/config/scripts/astman.js
> URL: http://svn.digium.com/view/asterisk-gui/trunk/config/scripts/astman.js?view=diff&rev=1201&r1=1200&r2=1201
> ==============================================================================
> --- trunk/config/scripts/astman.js (original)
> +++ trunk/config/scripts/astman.js Tue Jul  3 14:05:14 2007
> @@ -1122,7 +1122,11 @@
>  			target=target.parentNode;
>  		me.selecttarget = target.id;
>  		target.className = "chanlistselected";
> -		me.chancallback(target.id);
> +
> +		if(channelsCallback ){
> +			channelsCallback (target.id);
> +		}
> +		//me.chancallback(target.id);
>  	};
>  
>  	this.restoreTarget = function(targetname) {
> @@ -1219,7 +1223,7 @@
>  					foundactive = 1;
>  				}
>  				count++;
> -				s = s + "\t<tr class='" + cclass + "' id='" + channels[x].channel + "' onClick='parent.astmanEngine.clickChannel(event)'>";
> +				s = s + "\t<tr class='" + cclass + "' id='" + channels[x].channel + "' onClick='astmanEngine.clickChannel(event)'>";
>  				s = s + "<td class='field_text'>" + channels[x].channel + "</td>";
>  				if (channels[x].state)
>  					s = s + "<td class='field_text'>" + channels[x].state + "</td>";
> @@ -1391,11 +1395,7 @@
>  				} else if (override || (widgets[x].value != thevalue)) {
>  					if (cat.fieldbyname) {
>  						cat.fieldbyname[src] = widgets[x].value;
> -						if(widgets[x].hasAttribute('noblank') && !widgets[x].value){
> -							changes += build_action('delete', count++, cat.name, src, "", thevalue);
> -						}else{
> -							changes += build_action('update', count++, cat.name, src, cat.fieldbyname[src]);
> -						}
> +						changes += build_action('update', count++, cat.name, src, cat.fieldbyname[src]);
>  					} else
>  						cat[src] = widgets[src].value;
>  				}
>
> Modified: trunk/config/setup/1.html
> URL: http://svn.digium.com/view/asterisk-gui/trunk/config/setup/1.html?view=diff&rev=1201&r1=1200&r2=1201
> ==============================================================================
> --- trunk/config/setup/1.html (original)
> +++ trunk/config/setup/1.html Tue Jul  3 14:05:14 2007
> @@ -144,7 +144,7 @@
>  	"Action-000011=append&Cat-000011=" + asterisk_guitools + "&Var-000011=exten&Value-000011=" +
>  	encodeURI(		'play_file,n,Hangup' 	) + "&" + 
>  
> -	"Action-000012=append&Cat-000012=" + asterisk_guitools + "&Var-000012=hasbeensetup&Value-000012=" + 'Y';
> +	"Action-000012=append&Cat-000012=" + asterisk_guitools + "&Var-000012=hasbeensetup&Value-000012=" + 'N';
>  
>  	var tmp = new Ajax.Request(rawman_url, opt);
>  }
>
> Modified: trunk/config/trunks.html
> URL: http://svn.digium.com/view/asterisk-gui/trunk/config/trunks.html?view=diff&rev=1201&r1=1200&r2=1201
> ==============================================================================
> --- trunk/config/trunks.html (original)
> +++ trunk/config/trunks.html Tue Jul  3 14:05:14 2007
> @@ -35,12 +35,10 @@
>  		'name','new','port','provider','registeriax','registersip','save','secret','trunkname','trunkstyleanalog','trunkstylecustomvoip',
>  		'trunkstylevoip','username','zapchan'];
>  var provfieldnames = ['providerdesc', 'providerlogo'];
> -var opt_userandpass = ['voip_user', 'voip_pass', 'username', 'secret'];
>  var isnewtrunk;
>  var dids_array = [];
>  var old_trunkname;
>  var used_fxos = {};
> -var isdouble = 0;
>  used_fxos.oldvalue = "";
>  used_fxos.newvalue = "";
>  
> @@ -180,7 +178,7 @@
>  	var _msg3 = "When using Analog, at least one port must be selected.";
>  	var _msg4 = "Please enter a Comment for this Service Provider";
>  
> -	if ( _tsv.checked && !_$('username').value.length && _$('provider').value != "bandwidth") { gui_alert(_msg1); return false; }
> +	if ( _tsv.checked && !_$('username').value.length ) { gui_alert(_msg1); return false; }
>  
>  	if ( _tsa.checked ) {
>  		var _zapchan = _$('zapchan');
> @@ -324,24 +322,17 @@
>  	var _provider = _$('provider');
>  	var _zapchan = _$('zapchan');
>  	var _trunkname = _$('trunkname');
> -	var _username2 = (_$('username').value) ? ' - ' + _$('username').value : ' - (No Username Needed)'; 
>  	_$('hasexten').value = 'no';
>  	_$('context').value =  asterisk_guiTDPrefix + _$('name').value  ;
>  
>  	if (_$('trunkstylevoip').checked) {
>  		provider = _provider.stored_config.catbyname[_provider.value];
> -		_trunkname.value = _provider.options[_provider.selectedIndex].innerHTML + _username2;
> +		_trunkname.value = _provider.options[_provider.selectedIndex].innerHTML + " - " + _$('username').value;
>  		_$('hassip').value = provider.fieldbyname['hassip'];
>  		_$('hasiax').value = provider.fieldbyname['hasiax'];
>  		_$('registeriax').value = provider.fieldbyname['registeriax'];
>  		_$('registersip').value = provider.fieldbyname['registersip'];
> -		if(isdouble == 1) { /* Since we need an input and output trunk, we need to create yet another. */
> -			_$('host').value = provider.fieldbyname['host_in'];
> -			//_$('host').value = provider.fieldbyname['host_out'];
> -		} else {
> -			_$('host').value = provider.fieldbyname['host'];
> -		}
> -
> +		_$('host').value = provider.fieldbyname['host'];
>  		for (var x=0;x<_zapchan.options.length;x++){  _zapchan.options[x].selected = false; }
>  		_zapchan.value = '';
>  		_$('group').value = '';
> @@ -495,9 +486,6 @@
>  	}else if (_$('trunkstylevoip').checked) {
>  		_$('voip').style.display = "";
>  		_$('voip').style.height =350;
> -		for(var x=0; x < opt_userandpass.length; x++) {
> -		_$(opt_userandpass[x]).style.display = "none";
> -		}
>  	}else if (_$('trunkstylecustomvoip').checked) {
>  		_$('customvoip').style.display = "" ;
>  	}
> @@ -505,7 +493,6 @@
>  
>  function localajaxinit() {
>  	ASTGUI.events.add(document, 'mouseover', show_tooltip);
> -	ASTGUI.events.add(_$('provider'), 'click', showhidefields);
>  	setWindowTitle("Service Providers");
>  	_$('devices').contentEditable = 'false';
>  	_$('zapchan').splitchar=',';
> @@ -525,34 +512,17 @@
>  	) ;
>  
>  	for (var x =0; x< fieldnames.length; x++) {
> -		if(!_$(fieldnames[x])) {
> -			alert(fieldnames[x] + " does not exists.");
> -		}
>  		widgets[fieldnames[x]] = _$(fieldnames[x]);
>  		widgets[fieldnames[x]].disabled = true;
>  	}
> -	for (var x =0; x < provfieldnames.length ; x++) { 
> +	for (var x =0; x < provfieldnames.length ; x++) {
>  		provwidgets[provfieldnames[x]] = _$(provfieldnames[x]);
>  		provwidgets[provfieldnames[x]].disabled = true;
>  	}
> -	
> -	
> +
>  	parent.astmanEngine.config2list("zapscan.conf", _$('zapchan'), new Array(), phonecallbacks);
>  }
>  
> -function showhidefields() {
> -	var provname = _$('provider').value;
> -	if(provname == "bandwidth") {
> -		for(var x=0; x < opt_userandpass.length; x++) {
> -		_$(opt_userandpass[x]).style.display="none";	
> -		}
> -	} else {
> -		for(var x=0; x < opt_userandpass.length; x++) {
> -		_$(opt_userandpass[x]).style.display = "";
> -		}
> -	}
> -	
> -}
>  
>  function loadServiceProvidersintotable(){
>  	var _spt = _$('serviceproviderstable');
> @@ -1046,10 +1016,10 @@
>  	</tr>
>  	<tr><td colspan='2' align='center'><A href="#" id="providerlink"><img id='providerlogo' style='visibility:hidden;' border=0></A></td></tr>
>  	<tr><td colspan='2' align='center'><div id='providerdesc' align='left' style='width:230px;height:100px; font-size:10px'></div></td></tr>
> -	<tr>	<td id='voip_user' class="field_text" tip="en,trunks,3">Username:</td>
> +	<tr>	<td class="field_text" tip="en,trunks,3">Username:</td>
>  		<td><input size='20' id='username' class="input8"></td>
>  	</tr>
> -	<tr>	<td id='voip_pass' class="field_text" tip="en,trunks,4">Password:</td>
> +	<tr>	<td class="field_text" tip="en,trunks,4">Password:</td>
>  		<td><input type="password" size='20' id='secret' class="input8"></td>
>  	</tr>
>  	</table>
>
>
> _______________________________________________
> --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
>   


_______________________________________________
--Bandwidth and Colocation Provided by http://www.api-digital.com--

asterisk-gui mailing list
To UNSUBSCRIBE or update options visit:
   http://lists.digium.com/mailman/listinfo/asterisk-gui




More information about the asterisk-gui mailing list