adamsaghy commented on code in PR #5761:
URL: https://github.com/apache/fineract/pull/5761#discussion_r3274021624


##########
fineract-core/src/main/java/org/apache/fineract/portfolio/savings/domain/SavingsHelper.java:
##########
@@ -166,14 +167,28 @@ private LocalDate 
determineInterestPostingPeriodEndDateFrom(final LocalDate peri
                 } else {
                     periodEndDate = 
periodStartDate.withMonth(financialYearBeginningMonth);
                 }
-                periodEndDate = 
periodEndDate.with(TemporalAdjusters.lastDayOfMonth());
+                periodEndDate = 
periodEndDate.with(TemporalAdjusters.lastDayOfMonth()).plusDays(1);
+            break;
+            case ANNIVERSARY_MONTHLY:
+                periodEndDate = 
adjustToAnniversaryDay(periodStartDate.plusMonths(1), anniversaryDayOfMonth);
+            break;
+            case ANNIVERSARY_QUARTERLY:
+                periodEndDate = 
adjustToAnniversaryDay(periodStartDate.plusMonths(3), anniversaryDayOfMonth);
+            break;
+            case ANNIVERSARY_BIANNUAL:
+                periodEndDate = 
adjustToAnniversaryDay(periodStartDate.plusMonths(6), anniversaryDayOfMonth);
+            break;
+            case ANNIVERSARY_ANNUAL:
+                periodEndDate = 
adjustToAnniversaryDay(periodStartDate.plusMonths(12), anniversaryDayOfMonth);
             break;
         }
-        // interest posting always occurs on next day after the period end 
date.

Review Comment:
   Please put this comment on top of every places where we are adding an extra 
day to explain the reason:
   `// interest posting always occurs on next day after the period end date.`



-- 
This is an automated message from the Apache Git Service.
To respond to the message, please log on to GitHub and use the
URL above to go to the specific comment.

To unsubscribe, e-mail: [email protected]

For queries about this service, please contact Infrastructure at:
[email protected]

Reply via email to