← Back to team overview

dhis2-devs team mailing list archive

[Branch ~dhis2-devs-core/dhis2/trunk] Rev 3377: small paging fix

 

------------------------------------------------------------
revno: 3377
committer: Morten Olav Hansen <mortenoh@xxxxxxxxx>
branch nick: dhis2
timestamp: Wed 2011-04-13 11:13:36 +0200
message:
  small paging fix
modified:
  dhis-2/dhis-web/dhis-web-commons-resources/src/main/webapp/dhis-web-commons/javascripts/commons.js


--
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/dhis-web-commons/javascripts/commons.js'
--- dhis-2/dhis-web/dhis-web-commons-resources/src/main/webapp/dhis-web-commons/javascripts/commons.js	2011-04-11 16:43:51 +0000
+++ dhis-2/dhis-web/dhis-web-commons-resources/src/main/webapp/dhis-web-commons/javascripts/commons.js	2011-04-13 09:13:36 +0000
@@ -1391,6 +1391,12 @@
 function changePageSize( baseLink )
 {
     var pageSize = jQuery("#sizeOfPage").val();
+    
+    if(pageSize < 1)
+    {
+    	pageSize = 1;
+    }
+    
 	var currentPage = jQuery("#jumpToPage").val();
 	jQuery.cookie("pageSize", pageSize, {path: "/"});
     window.location.href = baseLink +"pageSize=" + pageSize +"&currentPage=" +currentPage;