pari: branch aadk r1082 - in /branches/aadk: ./ config/ config/graphs/ config...
SVN commits to the Asterisk-GUI project
asterisk-gui-commits at lists.digium.com
Mon Jun 18 09:36:52 CDT 2007
Author: pari
Date: Mon Jun 18 09:36:51 2007
New Revision: 1082
URL: http://svn.digium.com/view/asterisk-gui?view=rev&rev=1082
Log:
Merged revisions 433-435,437-447,449,489-500,506,508-510,513-518,520-531,533-535,537,539-540,542,544,546,548,550,552,554,556-557,559,562,564-566,569,571,573-577,580-586,589-604,606-611,614-616,618-619,621-622,624-625,633-634,636,638-640,648-650,660-676,678-679,682-684,687-688,695-696,698-702,704-712,714-716,718-719,721-722,724-725,727-746,749-750,752-753,757-767,769-771,774-780,782-783,785-786,788-789,791-792,794-795,797-800,802-803,808-810,812-816,821-825,827-835,837,839-840,842-847,849-850,853-855,862-864,867,869-870,873-878,880,884-886,889-898,900-903,906-909,911,917,939-940,946,948,950,956-960,962-963,967,971-976,984,989,1022-1030,1032,1035-1043,1050-1055,1057-1060,1062-1063,1065-1067,1069-1081 via svnmerge from
https://origsvn.digium.com/svn/asterisk-gui/trunk
........
r1072 | pari | 2007-06-10 02:00:53 -0500 (Sun, 10 Jun 2007) | 1 line
Tilghman just pointed this - http://lists.digium.com/pipermail/asterisk-dev/2007-June/028035.html, this also exposed a bug in with 'delcat' action - will be reporting soon in the bug tracker
........
r1073 | bkruse | 2007-06-11 18:13:17 -0500 (Mon, 11 Jun 2007) | 1 line
Updated todo.txt for stuff todo tomorrow, including the application specific arguments being easily accessible...added or destroyed from astman.js
........
r1074 | bkruse | 2007-06-13 15:55:34 -0500 (Wed, 13 Jun 2007) | 1 line
Added initial support for bandwidth.com. Todo: Add rules for incoming and outgoing calls so that they obey and align accordingly to bandwidth.com's specifications. This inclues adding the + sign before dialing out, and stripping it off when coming in.
........
r1075 | bkruse | 2007-06-13 16:29:55 -0500 (Wed, 13 Jun 2007) | 1 line
If I take away the username field, since its IP based authentication, I should probably take away the warning message also
........
r1076 | bkruse | 2007-06-13 16:40:15 -0500 (Wed, 13 Jun 2007) | 1 line
Added support to be able to tell if its a Bandwidth account or not. If it is, it will show you it does not need a username, instead of leaving it blank, which can be confusing
........
r1077 | bkruse | 2007-06-13 16:54:50 -0500 (Wed, 13 Jun 2007) | 1 line
More changes for bandwidth.com.....we have to make 2 trunks, one for incoming and one for outgoing.
........
r1078 | bkruse | 2007-06-13 17:13:14 -0500 (Wed, 13 Jun 2007) | 1 line
More changes for bandwidth.com. Time to start testing.... After this we will edit the incoming and outgoing rules to do the appending and stripping of the + sign...
........
r1079 | bkruse | 2007-06-14 22:37:56 -0500 (Thu, 14 Jun 2007) | 1 line
Please, someone tell be if im wrong...but if they go through the setup, shouldnt hasbeensetup be set to yes instead of no? This could be the reason for all the 'redirecting to setup page randomly' requests we have been hearing. Well, if it is, its fixed :D
........
r1080 | pari | 2007-06-18 04:00:09 -0500 (Mon, 18 Jun 2007) | 1 line
Fix: Graphs page sending too many requests when data_cpu.html is 404
........
Added:
branches/aadk/config/images/bandwidth.gif
- copied unchanged from r1080, trunk/config/images/bandwidth.gif
Modified:
branches/aadk/ (props changed)
branches/aadk/config/graphs.html
branches/aadk/config/graphs/graph_cpu.svgz
branches/aadk/config/scripts/astman.js
branches/aadk/config/setup/1.html
branches/aadk/config/trunks.html
branches/aadk/configs/providers.conf.sample
branches/aadk/todo.txt
Propchange: branches/aadk/
------------------------------------------------------------------------------
--- svnmerge-integrated (original)
+++ svnmerge-integrated Mon Jun 18 09:36:51 2007
@@ -1,1 +1,1 @@
-/trunk:1-430,433-449,489-501,505-506,508-510,512-540,542-557,559,561-577,580-586,588-616,618-767,769-1069
+/trunk:1-430,433-449,489-501,505-506,508-510,512-540,542-557,559,561-577,580-586,588-616,618-767,769-1081
Modified: branches/aadk/config/graphs.html
URL: http://svn.digium.com/view/asterisk-gui/branches/aadk/config/graphs.html?view=diff&rev=1082&r1=1081&r2=1082
==============================================================================
--- branches/aadk/config/graphs.html (original)
+++ branches/aadk/config/graphs.html Mon Jun 18 09:36:51 2007
@@ -81,42 +81,10 @@
return true;
}
-function getsysinfohtml(){
- var opt = {
- method: 'get',
- asynchronous: true,
- onComplete: function(originalRequest){
- _$('sysinfohtml').innerHTML = originalRequest.responseText;
- _$('osversion').innerHTML = _$('si_uname').innerHTML;
- _$('uptime').innerHTML = _$('si_uptime').innerHTML;
- _$('asterisk').innerHTML =_$('si_astver').innerHTML + "<BR>" + "Asterisk GUI-version " + asterisk_guiversion.substr(1) ;
- _$('today').innerHTML = _$('si_date').innerHTML;
- _$('hostname').innerHTML =_$('si_hostname').innerHTML;
- _$('ifconfig').innerHTML =_$('si_ifconfig').innerHTML;
- _$('diskusage').innerHTML = _$('si_du').innerHTML;
- _$('memoryusage').innerHTML =_$('si_free').innerHTML;
-
- var divs_toshow = new Array('osversion_div', 'uptime_div', 'asterisk_div', 'today_div','hostname_div');
- for(var i=0; i < divs_toshow.length; i++ ){ _$(divs_toshow[i]).style.display = ""; }
-
- document.getElementById(tabs[0]).className = "tabselected";
- load_todayslog();
- },
- onFailure: function(t) {
- _$('status_message').style.display='none';
- gui_alert("Config Error: " + t.status + ": " + t.statusText);
- }
- };
- opt.parameters="";
- var tmp = new Ajax.Request("./bkps/sysinfo_output.html", opt);
- return true;
-}
-
-
function localajaxinit(){
ASTGUI.events.add(document, 'mouseover', show_tooltip);
setWindowTitle("Resource and Monitoring Graphs");
- var date = new Date() ;
+ var date = new Date() ;
parent.loadscreen(this);
show_window(1);
}
@@ -137,20 +105,18 @@
<div class="mainscreenContentBox" id="userscontent">
<table class="mainscreenTable" align="center">
<tr valign="top" height="18">
- <td align="left">
-
- <a href="#" class="tab" onclick="return show_window(1);" id="tab1" tip="en,graph,0">CPU</a>
- <div id="graphshtml" style="display:none"></div>
-
- <div id="information" style=" border: solid 0px black; background: transparent; padding: 4px; height:440px; width:95%;">
- <BR>
- <div id="cpu_div" style="display:none">
- <div id="cpu" style="font-family:courier; font-size:10pt;"></div><BR>
- <embed id="cpu_embed" type="image/svg+xml" src="graphs/graph_cpu.svgz"
- width="500" height="250" />
- </div>
- </div>
- </td>
+ <td align="left">
+ <a href="#" class="tab" onclick="return show_window(1);" id="tab1" tip="en,graph,0">CPU</a>
+ <div id="graphshtml" style="display:none"></div>
+ <div id="information" style=" border: solid 0px black; background: transparent; padding: 4px; height:440px; width:95%;">
+ <BR>
+ <div id="cpu_div" style="display:none">
+ <div id="cpu" style="font-family:courier; font-size:10pt;"></div><BR>
+ <embed id="cpu_embed" type="image/svg+xml" src="graphs/graph_cpu.svgz"
+ width="500" height="250" />
+ </div>
+ </div>
+ </td>
</tr>
<tr><td valign="top" align=center><div id='status'></div></td></tr>
<tr><td></td></tr>
Modified: branches/aadk/config/graphs/graph_cpu.svgz
URL: http://svn.digium.com/view/asterisk-gui/branches/aadk/config/graphs/graph_cpu.svgz?view=diff&rev=1082&r1=1081&r2=1082
==============================================================================
--- branches/aadk/config/graphs/graph_cpu.svgz (original)
+++ branches/aadk/config/graphs/graph_cpu.svgz Mon Jun 18 09:36:51 2007
@@ -86,12 +86,22 @@
throw 'Both getURL and XMLHttpRequest are undefined';
http_request.onreadystatechange = function() {
+
if (http_request.readyState == 4) {
- callback( { success : true,
- content : http_request.responseText,
- contentType : http_request.getResponseHeader("Content-Type") } );
+ if( String(http_request.status) == '404' ){
+ SVGDoc.getElementById('collect_initial').setAttributeNS(null, 'visibility', 'visible');
+ return;
+ }
+ callback({
+ success : true,
+ content : http_request.responseText,
+ contentType : http_request.getResponseHeader("Content-Type")
+ });
+
+
}
}
+
http_request.open('GET', url, true);
http_request.send(null);
}
Modified: branches/aadk/config/scripts/astman.js
URL: http://svn.digium.com/view/asterisk-gui/branches/aadk/config/scripts/astman.js?view=diff&rev=1082&r1=1081&r2=1082
==============================================================================
--- branches/aadk/config/scripts/astman.js (original)
+++ branches/aadk/config/scripts/astman.js Mon Jun 18 09:36:51 2007
@@ -291,10 +291,12 @@
g = t[r].indexOf(":") ;
catname = t[r].substr(g+1) ; // category
catname = catname.replace(/^\s*|\s*$/g,'') ; // trim
- if(!p){
- a[catname] = [];
- }else{
- a[catname] = {};
+ if(!a[catname]){ // contexts could be spread at different places in the config file
+ if(!p){
+ a[catname] = [];
+ }else{
+ a[catname] = {};
+ }
}
}else if ( h == "line" ){
j = t[r].indexOf(":") ;
Modified: branches/aadk/config/setup/1.html
URL: http://svn.digium.com/view/asterisk-gui/branches/aadk/config/setup/1.html?view=diff&rev=1082&r1=1081&r2=1082
==============================================================================
--- branches/aadk/config/setup/1.html (original)
+++ branches/aadk/config/setup/1.html Mon Jun 18 09:36:51 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=" + 'N';
+ "Action-000012=append&Cat-000012=" + asterisk_guitools + "&Var-000012=hasbeensetup&Value-000012=" + 'Y';
var tmp = new Ajax.Request(rawman_url, opt);
}
Modified: branches/aadk/config/trunks.html
URL: http://svn.digium.com/view/asterisk-gui/branches/aadk/config/trunks.html?view=diff&rev=1082&r1=1081&r2=1082
==============================================================================
--- branches/aadk/config/trunks.html (original)
+++ branches/aadk/config/trunks.html Mon Jun 18 09:36:51 2007
@@ -35,10 +35,12 @@
'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 = "";
@@ -178,7 +180,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 ) { gui_alert(_msg1); return false; }
+ if ( _tsv.checked && !_$('username').value.length && _$('provider').value != "bandwidth") { gui_alert(_msg1); return false; }
if ( _tsa.checked ) {
var _zapchan = _$('zapchan');
@@ -322,17 +324,24 @@
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 + " - " + _$('username').value;
+ _trunkname.value = _provider.options[_provider.selectedIndex].innerHTML + _username2;
_$('hassip').value = provider.fieldbyname['hassip'];
_$('hasiax').value = provider.fieldbyname['hasiax'];
_$('registeriax').value = provider.fieldbyname['registeriax'];
_$('registersip').value = provider.fieldbyname['registersip'];
- _$('host').value = provider.fieldbyname['host'];
+ 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'];
+ }
+
for (var x=0;x<_zapchan.options.length;x++){ _zapchan.options[x].selected = false; }
_zapchan.value = '';
_$('group').value = '';
@@ -486,6 +495,9 @@
}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 = "" ;
}
@@ -493,6 +505,7 @@
function localajaxinit() {
ASTGUI.events.add(document, 'mouseover', show_tooltip);
+ ASTGUI.events.add(_$('provider'), 'click', showhidefields);
setWindowTitle("Service Providers");
_$('devices').contentEditable = 'false';
_$('zapchan').splitchar=',';
@@ -512,17 +525,34 @@
) ;
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');
@@ -1016,10 +1046,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 class="field_text" tip="en,trunks,3">Username:</td>
+ <tr> <td id='voip_user' class="field_text" tip="en,trunks,3">Username:</td>
<td><input size='20' id='username' class="input8"></td>
</tr>
- <tr> <td class="field_text" tip="en,trunks,4">Password:</td>
+ <tr> <td id='voip_pass' class="field_text" tip="en,trunks,4">Password:</td>
<td><input type="password" size='20' id='secret' class="input8"></td>
</tr>
</table>
Modified: branches/aadk/configs/providers.conf.sample
URL: http://svn.digium.com/view/asterisk-gui/branches/aadk/configs/providers.conf.sample?view=diff&rev=1082&r1=1081&r2=1082
==============================================================================
--- branches/aadk/configs/providers.conf.sample (original)
+++ branches/aadk/configs/providers.conf.sample Mon Jun 18 09:36:51 2007
@@ -10,3 +10,17 @@
host = iaxtel.com
;trunk_username = iaxtel ; if set - the trunk created by the GUI will be by this name instead of trunk_x
regurl = http://www.iaxtel.com ; URL to providers home/signup page
+
+[bandwidth]
+providername = Bandwidth
+providerlogo = images/bandwidth.gif
+protocol = sip
+providerdesc = Bandwidth.com's SIP (Session Initiation Protocol) Trunking solution, combined with an IP-PBX, enables organizations to save money by consolidating their voice and data over a single IP circuit -- maximizing its usage by utilizing unused bandwidth. Note: No username or password required. Bandwidth.com uses IP based Authentication.
+hasiax = no
+hassip = yes
+port = 5060
+registeriax = no
+registersip = no
+host = 4.79.212.236
+;host_out = 216.82.224.202
+regurl = http://bandwidth.com
Modified: branches/aadk/todo.txt
URL: http://svn.digium.com/view/asterisk-gui/branches/aadk/todo.txt?view=diff&rev=1082&r1=1081&r2=1082
==============================================================================
--- branches/aadk/todo.txt (original)
+++ branches/aadk/todo.txt Mon Jun 18 09:36:51 2007
@@ -30,6 +30,12 @@
* All system path variables should be able to edit via GUI.
+* If the timeout option for the dial app is not set, do not add a comma ;[ I will fix this tomorrow, along with other options for the Dial() app inside ringgroups.html (where the problem currently exists.)
+
+* In addition to build_action, if you are updating an extension, be able to easily add application specific parameteres
+
+* Add full support for bandwidth.com through the service providers page
+
Completed
----------
@@ -44,3 +50,5 @@
* Option to redirect a timerule to a ringGroup
* Make the GUI resolution independent - request from BSD_tech
+
+* Initial support for Bandwidth.com
More information about the asterisk-gui-commits
mailing list