dhis2-devs team mailing list archive
-
dhis2-devs team
-
Mailing list archive
-
Message #39205
[Branch ~dhis2-devs-core/dhis2/trunk] Rev 19879: Minor bugfix, use calendar parameter instead of getCalendar in FinancialPeriodType.createPeriod
------------------------------------------------------------
revno: 19879
committer: Morten Olav Hansen <mortenoh@xxxxxxxxx>
branch nick: dhis2
timestamp: Fri 2015-08-28 14:27:07 +0700
message:
Minor bugfix, use calendar parameter instead of getCalendar in FinancialPeriodType.createPeriod
modified:
dhis-2/dhis-api/src/main/java/org/hisp/dhis/period/FinancialPeriodType.java
--
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-api/src/main/java/org/hisp/dhis/period/FinancialPeriodType.java'
--- dhis-2/dhis-api/src/main/java/org/hisp/dhis/period/FinancialPeriodType.java 2015-01-17 07:41:26 +0000
+++ dhis-2/dhis-api/src/main/java/org/hisp/dhis/period/FinancialPeriodType.java 2015-08-28 07:27:07 +0000
@@ -65,7 +65,7 @@
if ( !past )
{
- dateTimeUnit = getCalendar().minusYears( dateTimeUnit, 1 );
+ dateTimeUnit = calendar.minusYears( dateTimeUnit, 1 );
}
dateTimeUnit.setMonth( getBaseMonth() + 1 );
@@ -74,8 +74,8 @@
DateTimeUnit start = new DateTimeUnit( dateTimeUnit );
DateTimeUnit end = new DateTimeUnit( dateTimeUnit );
- end = getCalendar().plusYears( end, 1 );
- end = getCalendar().minusDays( end, 1 );
+ end = calendar.plusYears( end, 1 );
+ end = calendar.minusDays( end, 1 );
return toIsoPeriod( start, end, calendar );
}