pari: branch 2.0 r3856 - /branches/2.0/config/welcome.html

SVN commits to the Asterisk-GUI project asterisk-gui-commits at lists.digium.com
Mon Sep 22 17:04:16 CDT 2008


Author: pari
Date: Mon Sep 22 17:04:16 2008
New Revision: 3856

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

 Also show duration of each conference room



Modified:
    branches/2.0/config/welcome.html

Modified: branches/2.0/config/welcome.html
URL: http://svn.digium.com/view/asterisk-gui/branches/2.0/config/welcome.html?view=diff&rev=3856&r1=3855&r2=3856
==============================================================================
--- branches/2.0/config/welcome.html (original)
+++ branches/2.0/config/welcome.html Mon Sep 22 17:04:16 2008
@@ -352,31 +352,33 @@
 	})();
 
 	(function(){ // List all meetMe Extensions
+		var active_conferences = {};
+		(function(){
+			var meetme_status = ASTGUI.cliCommand('meetme');
+			meetme_status = parent.ASTGUI.parseCLIResponse(meetme_status);
+			if ( meetme_status.contains('No active MeetMe conferences') ){
+				// No active MeetMe conferences.
+			}else{
+				// sx00i*CLI> meetme
+				// Conf Num       Parties        Marked     Activity  Creation
+				// 6302           0001           N/A        00:00:09  Static
+				// 6300           0001           N/A        00:02:51  Static
+				// * Total number of MeetMe users: 2
+				meetme_status = meetme_status.split('\n');
+				while( meetme_status.length ){
+					var this_line = meetme_status[0];
+					meetme_status.removeFirst();
+					this_line = this_line.trim();
+					if( !this_line || this_line.beginsWith('Conf Num') ||  this_line.beginsWith('* Total number') ) { continue; }
+					var tmp_vars = this_line.split(/\s+/); // ['6302','0001','N/A','00:00:09', 'Static' ]
+					active_conferences[ tmp_vars[0] ] = {} ;
+					active_conferences[ tmp_vars[0] ]['count'] = tmp_vars[1] ;
+					active_conferences[ tmp_vars[0] ]['duration'] = tmp_vars[3] ;
+				}
+			}
+		})();
+
 		var m = parent.sessionData.pbxinfo.conferences ;
-		var meetme_status = ASTGUI.cliCommand('meetme');
-		meetme_status = parent.ASTGUI.parseCLIResponse(meetme_status);
-		var active_conferences = {};
-
-		if ( meetme_status.contains('No active MeetMe conferences') ){
-			// No active MeetMe conferences.
-		}else{
-			// sx00i*CLI> meetme
-			// Conf Num       Parties        Marked     Activity  Creation
-			// 6302           0001           N/A        00:00:09  Static
-			// 6300           0001           N/A        00:02:51  Static
-			// * Total number of MeetMe users: 2
-			meetme_status = meetme_status.split('\n');
-
-			while( meetme_status.length ){
-				var this_line = meetme_status[0];
-				meetme_status.removeFirst();
-				this_line = this_line.trim();
-				if( !this_line || this_line.beginsWith('Conf Num') ||  this_line.beginsWith('* Total number') ) {continue;}
-				var tmp_vars = this_line.split(/\s+/); // ['6302','0001','N/A','00:00:09', 'Static' ]
-				active_conferences[ tmp_vars[0] ] = tmp_vars[1] ;
-			}
-		}
-
 		for( l in m ){ if( m.hasOwnProperty(l) && l !='admin'){
 				var newRow = DOM_table_Ext_list.insertRow(-1);
 				newRow.className = ((DOM_table_Ext_list.rows.length)%2==1)?'odd':'even';
@@ -385,7 +387,7 @@
 				addCell( newRow , { html: '<b>Conference Room</b>' });
 
 				if( active_conferences.hasOwnProperty(l) ){
-					addCell( newRow , { html: '<font color=red>' + Number(active_conferences[l]) + ' Users</font>' });
+					addCell( newRow , { html: '<font color=red>' + Number(active_conferences[l].count) + ' Users</font> - ' + active_conferences[l].duration });
 				}else{
 					addCell( newRow , { html: '<font color=green>Not in use</font>' });
 				}




More information about the asterisk-gui-commits mailing list