bkruse: trunk r1569 - in /trunk: ./ config/digital.html config/timerules.html

SVN commits to the Asterisk-GUI project asterisk-gui-commits at lists.digium.com
Mon Sep 10 15:18:10 CDT 2007


Author: bkruse
Date: Mon Sep 10 15:18:10 2007
New Revision: 1569

URL: http://svn.digium.com/view/asterisk-gui?view=rev&rev=1569
Log:
Merged revisions 1568 via svnmerge from 
https://origsvn.digium.com/svn/asterisk-gui/branches/1.4

........
r1568 | bkruse | 2007-09-10 15:17:04 -0500 (Mon, 10 Sep 2007) | 4 lines

Another awesome commit. Now it will actually 
show you the settings applied, instead of starting
fresh each time.

........

Modified:
    trunk/   (props changed)
    trunk/config/digital.html
    trunk/config/timerules.html

Propchange: trunk/
------------------------------------------------------------------------------
Binary property 'branch-1.4-merged' - no diff available.

Modified: trunk/config/digital.html
URL: http://svn.digium.com/view/asterisk-gui/trunk/config/digital.html?view=diff&rev=1569&r1=1568&r2=1569
==============================================================================
--- trunk/config/digital.html (original)
+++ trunk/config/digital.html Mon Sep 10 15:18:10 2007
@@ -336,10 +336,10 @@
 				_class = 0;
 			}
 			/* if alarms is red, make cell red, else make cell green/yellow etc. */
+			SPANS[l].en = new Array;
 			for(var i=0; i < fieldnames.length; i++) {
 				var td = document.createElement("td");
 				/* save our information for global use... */
-				SPANS[l].en = new Array;
 				SPANS[l].en[fieldnames[i]] = n[l][fieldnames[i]];
 				/* dumb hack because we cannot use multidimentional arrays */
 				if(fieldnames[i] == 'lbo' && n[l][fieldnames[i]] == "NODEF") {
@@ -472,21 +472,25 @@
 
 /* function to select the proper framing/coding || lbo and sync source as specified */
 function select_correct_index() {
+	var find_index = function(el,val,sec) {
+		for(var t=0; t < el.options.length; t++) {
+			if(sec == 'fac') {
+				var l = val.toLowerCase();
+				l = l.replace('/', ',');
+				if(el.options[t].value == l) { el.selectedIndex = t; return; }
+			} else {
+				if(el.options[t].value == val) { el.selectedIndex = t; return; }
+			}
+		}
+	}
+
 	for(var i=1; i < (total_spans + 1); i++ ){
 		for(var x=0; x < fieldnames_clickable.length; x++) {
 			var tmp_id = i+'-'+fieldnames_clickable[x]+'-sel';
-			var ofid = _$(tmp_id);
-			if(ofid) {
-				for(var w=0; w < fieldnames.length; w++) {
-				alert(ofid.options[w].value + SPAN[i].en['fac']);
-					if(ofid.options[w].value.length) {
-						if(ofid.options[w].value == SPAN[i].en['fac'])
-							alert("zomgz");
-					}
-				}
+			find_index(_$(tmp_id), SPANS[i].en[fieldnames_clickable[x]], fieldnames_clickable[x]);
 			}
 		}
-	}	
+	return true;
 }
 function save_changes() {
 	/* function to grab the values of fields, and call the bash script to apply the changes and run ztcfg */

Modified: trunk/config/timerules.html
URL: http://svn.digium.com/view/asterisk-gui/trunk/config/timerules.html?view=diff&rev=1569&r1=1568&r2=1569
==============================================================================
--- trunk/config/timerules.html (original)
+++ trunk/config/timerules.html Mon Sep 10 15:18:10 2007
@@ -446,6 +446,7 @@
 	_$('endtime_minute').selectedIndex = tm;
 
 	var find_index = function(el,val){
+		alert("el is " + el + " val is " + val);
 		for(var t=0; t< el.options.length; t++){
 			if( el.options[t].value == val){ el.selectedIndex = t; return; }
 		}




More information about the asterisk-gui-commits mailing list