diff options
author | Darren Embry <dse@webonastick.com> | 2012-04-06 19:45:25 -0400 |
---|---|---|
committer | Darren Embry <dse@webonastick.com> | 2012-04-06 19:45:25 -0400 |
commit | ee965a5c7bf37b852795e1201688e3b20bf3d8d1 (patch) | |
tree | d3b3a15069c22404c69ab872131a93b3c4fe09ed /usr/local/www/widgets/javascript | |
parent | 556e760dc0c91f993d3ae72977f03ca5ead30ba3 (diff) | |
download | pfsense-ee965a5c7bf37b852795e1201688e3b20bf3d8d1.zip pfsense-ee965a5c7bf37b852795e1201688e3b20bf3d8d1.tar.gz |
fix for Bug #2231 --- Dashboard: Traffic Graph: Unable to save settings
Diffstat (limited to 'usr/local/www/widgets/javascript')
-rw-r--r-- | usr/local/www/widgets/javascript/traffic_graph.js | 34 |
1 files changed, 3 insertions, 31 deletions
diff --git a/usr/local/www/widgets/javascript/traffic_graph.js b/usr/local/www/widgets/javascript/traffic_graph.js index 4970f25..9cdff97 100644 --- a/usr/local/www/widgets/javascript/traffic_graph.js +++ b/usr/local/www/widgets/javascript/traffic_graph.js @@ -1,5 +1,5 @@ function trafficshowDiv(incDiv,swapButtons){ - //appear element + //appear element selectedDiv = incDiv + "graphdiv"; jQuery('#' + selectedDiv).effect('blind',{mode:'show'},1000); showSave(); @@ -13,10 +13,7 @@ function trafficshowDiv(incDiv,swapButtons){ textlink = d.getElementById(selectIntLink); textlink.style.display = "none"; } - selectIntLink = incDiv + "_graph-config"; - textlink = d.getElementById(selectIntLink); - textlink.value = "show"; - updateGraphDisplays(); + document.iform["shown[" + incDiv + "]"].value = "show"; } function trafficminimizeDiv(incDiv,swapButtons){ @@ -34,31 +31,6 @@ function trafficminimizeDiv(incDiv,swapButtons){ textlink = d.getElementById(selectIntLink); textlink.style.display = "none"; } - selectIntLink = incDiv + "_graph-config"; - textlink = d.getElementById(selectIntLink); - textlink.value = "hide"; - updateGraphDisplays(); + document.iform["shown[" + incDiv + "]"].value = "hide"; } -function updateGraphDisplays(){ - var graphs = document.getElementsByClassName('graphsettings'); - var graphsdisplayed = ""; - var firstprint = false; - d = document; - for (i=0; i<graphs.length; i++){ - if (firstprint) - graphsdisplayed += ","; - var graph = graphs[i].id; - graphsdisplayed += graph + ":"; - textlink = d.getElementById(graph).value; - graphsdisplayed += textlink; - firstprint = true; - } - selectIntLink = "refreshInterval"; - graphsdisplayed += ",refreshInterval="; - graphsdisplayed += d.getElementById(selectIntLink).value; - - selectIntLink = "traffic_graphs-config"; - textlink = d.getElementById(selectIntLink); - textlink.value = graphsdisplayed; -} |