← Back to team overview

dhis2-devs team mailing list archive

[Branch ~dhis2-devs-core/dhis2/trunk] Rev 6822: Fixed minor bug with menu system

 

------------------------------------------------------------
revno: 6822
committer: Lars Helge Overland <larshelge@xxxxxxxxx>
branch nick: dhis2
timestamp: Tue 2012-05-01 15:14:33 +0200
message:
  Fixed minor bug with menu system
modified:
  dhis-2/dhis-web/dhis-web-commons-resources/src/main/webapp/main.js
  dhis-2/dhis-web/dhis-web-reporting/src/main/webapp/dhis-web-reporting/javascript/dataCompleteness.js
  dhis-2/dhis-web/dhis-web-reporting/src/main/webapp/dhis-web-reporting/javascript/dataSetReport.js
  dhis-2/dhis-web/dhis-web-reporting/src/main/webapp/dhis-web-reporting/javascript/orgUnitDistribution.js
  dhis-2/dhis-web/dhis-web-validationrule/src/main/resources/org/hisp/dhis/validationrule/i18n_module.properties
  dhis-2/dhis-web/dhis-web-validationrule/src/main/webapp/dhis-web-validationrule/javascript/runValidation.js
  dhis-2/dhis-web/dhis-web-validationrule/src/main/webapp/dhis-web-validationrule/searchResult.vm


--
lp:dhis2
https://code.launchpad.net/~dhis2-devs-core/dhis2/trunk

Your team DHIS 2 developers is subscribed to branch lp:dhis2.
To unsubscribe from this branch go to https://code.launchpad.net/~dhis2-devs-core/dhis2/trunk/+edit-subscription
=== modified file 'dhis-2/dhis-web/dhis-web-commons-resources/src/main/webapp/main.js'
--- dhis-2/dhis-web/dhis-web-commons-resources/src/main/webapp/main.js	2012-04-01 19:29:11 +0000
+++ dhis-2/dhis-web/dhis-web-commons-resources/src/main/webapp/main.js	2012-05-01 13:14:33 +0000
@@ -7,22 +7,8 @@
 
 function pageInit()
 {
-	// Zebra stripes in lists
+	setTableStyles();
 	
-	$( "table.listTable tbody tr:odd" ).addClass( "listAlternateRow" );
-    $( "table.listTable tbody tr:even" ).addClass( "listRow" );
-
-    // Hover rows in lists
-    
-    $( "table.listTable tbody tr" ).mouseover( function()
-    {
-    	$( this ).addClass( "listHoverRow" );
-    } );
-    $( "table.listTable tbody tr" ).mouseout( function()
-    {
-        $( this ).removeClass( "listHoverRow" );
-    } );
-    
     // Hover on rightbar close image
     
     $( "#hideRightBarImg" ).mouseover( function()
@@ -134,6 +120,25 @@
 	$( ".introList" ).fadeIn();
 }
 
+function setTableStyles()
+{
+	// Zebra stripes in lists
+	
+	$( "table.listTable tbody tr:odd" ).addClass( "listAlternateRow" );
+    $( "table.listTable tbody tr:even" ).addClass( "listRow" );
+
+    // Hover rows in lists
+    
+    $( "table.listTable tbody tr" ).mouseover( function()
+    {
+    	$( this ).addClass( "listHoverRow" );
+    } );
+    $( "table.listTable tbody tr" ).mouseout( function()
+    {
+        $( this ).removeClass( "listHoverRow" );
+    } );
+}
+
 // -----------------------------------------------------------------------------
 // Menu functions
 // -----------------------------------------------------------------------------
@@ -170,7 +175,7 @@
 
 function hideDropDownTimeout()
 {
-    closeTimer = window.setTimeout( hideDropDown, menuTimeout );
+    closeTimer = window.setTimeout( "hideDropDown()", menuTimeout );
 }
 
 function cancelHideDropDownTimeout()

=== modified file 'dhis-2/dhis-web/dhis-web-reporting/src/main/webapp/dhis-web-reporting/javascript/dataCompleteness.js'
--- dhis-2/dhis-web/dhis-web-reporting/src/main/webapp/dhis-web-reporting/javascript/dataCompleteness.js	2012-04-26 18:32:46 +0000
+++ dhis-2/dhis-web/dhis-web-reporting/src/main/webapp/dhis-web-reporting/javascript/dataCompleteness.js	2012-05-01 13:14:33 +0000
@@ -26,7 +26,7 @@
     $( "#contentDiv" ).load( url, function()
     {
         hideLoader();
-        pageInit();
+        setTableStyles();
     } );
 }
 

=== modified file 'dhis-2/dhis-web/dhis-web-reporting/src/main/webapp/dhis-web-reporting/javascript/dataSetReport.js'
--- dhis-2/dhis-web/dhis-web-reporting/src/main/webapp/dhis-web-reporting/javascript/dataSetReport.js	2012-04-26 15:26:28 +0000
+++ dhis-2/dhis-web/dhis-web-reporting/src/main/webapp/dhis-web-reporting/javascript/dataSetReport.js	2012-05-01 13:14:33 +0000
@@ -39,7 +39,7 @@
     $( '#content' ).load( 'generateDataSetReport.action', currentParams, function() {
     	hideLoader();
     	showContent();
-    	pageInit();
+    	setTableStyles();
     } );
 }
 

=== modified file 'dhis-2/dhis-web/dhis-web-reporting/src/main/webapp/dhis-web-reporting/javascript/orgUnitDistribution.js'
--- dhis-2/dhis-web/dhis-web-reporting/src/main/webapp/dhis-web-reporting/javascript/orgUnitDistribution.js	2012-04-26 18:32:46 +0000
+++ dhis-2/dhis-web/dhis-web-reporting/src/main/webapp/dhis-web-reporting/javascript/orgUnitDistribution.js	2012-05-01 13:14:33 +0000
@@ -15,7 +15,7 @@
     $( "#tableDiv" ).load( url, function()
     {
         displayDiv( "tableDiv", distributionDivs );
-        pageInit();
+        setTableStyles();
     } );
 }
 

=== modified file 'dhis-2/dhis-web/dhis-web-validationrule/src/main/resources/org/hisp/dhis/validationrule/i18n_module.properties'
--- dhis-2/dhis-web/dhis-web-validationrule/src/main/resources/org/hisp/dhis/validationrule/i18n_module.properties	2012-04-16 15:06:27 +0000
+++ dhis-2/dhis-web/dhis-web-validationrule/src/main/resources/org/hisp/dhis/validationrule/i18n_module.properties	2012-05-01 13:14:33 +0000
@@ -122,3 +122,4 @@
 get_report_as_pdf=Download as PDF
 max_values_exceeded=More than 500 values found, please fix the violations or narrow the search to see all
 specify_dataset=Please specify data sets
+analysing_please_wait=Analysing data, please wait
\ No newline at end of file

=== modified file 'dhis-2/dhis-web/dhis-web-validationrule/src/main/webapp/dhis-web-validationrule/javascript/runValidation.js'
--- dhis-2/dhis-web/dhis-web-validationrule/src/main/webapp/dhis-web-validationrule/javascript/runValidation.js	2012-02-22 18:07:04 +0000
+++ dhis-2/dhis-web/dhis-web-validationrule/src/main/webapp/dhis-web-validationrule/javascript/runValidation.js	2012-05-01 13:14:33 +0000
@@ -29,7 +29,7 @@
 	            $( 'div#analysisInput' ).hide();
 	            $( 'div#analysisResult' ).show();
 	            $( 'div#analysisResult' ).html( data );
-	            pageInit();
+	            setTableStyles();
 	        } );
 	    }
 	    else if ( json.response == 'input' )
@@ -52,7 +52,7 @@
     {
         hideHeaderMessage();
         $( "div#analysisResult" ).html( data );
-        pageInit();
+        setTableStyles();
     } );
 }
 

=== modified file 'dhis-2/dhis-web/dhis-web-validationrule/src/main/webapp/dhis-web-validationrule/searchResult.vm'
--- dhis-2/dhis-web/dhis-web-validationrule/src/main/webapp/dhis-web-validationrule/searchResult.vm	2012-02-22 17:43:09 +0000
+++ dhis-2/dhis-web/dhis-web-validationrule/src/main/webapp/dhis-web-validationrule/searchResult.vm	2012-05-01 13:14:33 +0000
@@ -1,7 +1,7 @@
 <script type="text/javascript">
 	jQuery(document).ready(function(){	
 		tableSorter( 'listTable' );	
-		pageInit();
+		setTableStyles();
 	});
 
     var i18n_value_must_be_a_number = '$encoder.jsEscape( $i18n.getString( "value_must_be_a_number" ) , "'")';