← Back to team overview

dhis2-devs team mailing list archive

[Branch ~dhis2-devs-core/dhis2/trunk] Rev 15025: minor fix

 

------------------------------------------------------------
revno: 15025
committer: Morten Olav Hansen <mortenoh@xxxxxxxxx>
branch nick: dhis2
timestamp: Sun 2014-04-27 20:46:39 +0545
message:
  minor fix
modified:
  dhis-2/dhis-web/dhis-web-commons-resources/src/main/webapp/dhis-web-commons/javascripts/dhis2/dhis2.period.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/dhis2/dhis2.period.js'
--- dhis-2/dhis-web/dhis-web-commons-resources/src/main/webapp/dhis-web-commons/javascripts/dhis2/dhis2.period.js	2014-04-27 15:00:23 +0000
+++ dhis-2/dhis-web/dhis-web-commons-resources/src/main/webapp/dhis-web-commons/javascripts/dhis2/dhis2.period.js	2014-04-27 15:01:39 +0000
@@ -41,10 +41,6 @@
     var endDate = cal.newDate(startDate).set(cal.monthsInYear(year + i), 'm');
     endDate.set(endDate.daysInMonth(endDate.month()), 'd');
 
-    if( startDate.year() != endDate.year() ) {
-      break;
-    }
-
     var period = {};
     period['startDate'] = startDate.formatDate(dhis2.period.DATE_FORMAT);
     period['endDate'] = endDate.formatDate(dhis2.period.DATE_FORMAT);
@@ -67,10 +63,6 @@
     var startDate = cal.newDate(year, month, 1);
     var endDate = cal.newDate(startDate).set(startDate.daysInMonth(month), 'd');
 
-    if( startDate.year() != endDate.year() ) {
-      break;
-    }
-
     var period = {};
     period['startDate'] = startDate.formatDate(dhis2.period.DATE_FORMAT);
     period['endDate'] = endDate.formatDate(dhis2.period.DATE_FORMAT);
@@ -94,10 +86,6 @@
     var endDate = cal.newDate(startDate).set(month + 1, 'm');
     endDate.set(endDate.daysInMonth(month + 1), 'd');
 
-    if( startDate.year() != endDate.year() ) {
-      break;
-    }
-
     var period = {};
     period['startDate'] = startDate.formatDate(dhis2.period.DATE_FORMAT);
     period['endDate'] = endDate.formatDate(dhis2.period.DATE_FORMAT);
@@ -121,10 +109,6 @@
     var endDate = cal.newDate(startDate).set(month + 2, 'm');
     endDate.set(endDate.daysInMonth(month + 2), 'd');
 
-    if( startDate.year() != endDate.year() ) {
-      break;
-    }
-
     var period = {};
     period['startDate'] = startDate.formatDate(dhis2.period.DATE_FORMAT);
     period['endDate'] = endDate.formatDate(dhis2.period.DATE_FORMAT);