diff --git a/fineract-core/src/main/java/org/apache/fineract/portfolio/savings/domain/SavingsHelper.java b/fineract-core/src/main/java/org/apache/fineract/portfolio/savings/domain/SavingsHelper.java index ad5bbfa82b..0a13f85d52 100644 --- a/fineract-core/src/main/java/org/apache/fineract/portfolio/savings/domain/SavingsHelper.java +++ b/fineract-core/src/main/java/org/apache/fineract/portfolio/savings/domain/SavingsHelper.java @@ -84,6 +84,7 @@ public List determineInterestPostingPeriods(final LocalDate s log.info( " --startInterestCalculationLocalDate-- {} -- Period Date is Huge here --interestPostingUpToDate-> {} ---interestPostingLocalDate->{}", startInterestCalculationLocalDate, interestPostingUpToDate, interestPostingLocalDate); + break; } } else { periodEndDate = interestPostingLocalDate.minusDays(1); diff --git a/fineract-savings/src/main/java/org/apache/fineract/portfolio/savings/domain/DepositAccountTermAndPreClosure.java b/fineract-savings/src/main/java/org/apache/fineract/portfolio/savings/domain/DepositAccountTermAndPreClosure.java index 31240765df..064dc36e8e 100644 --- a/fineract-savings/src/main/java/org/apache/fineract/portfolio/savings/domain/DepositAccountTermAndPreClosure.java +++ b/fineract-savings/src/main/java/org/apache/fineract/portfolio/savings/domain/DepositAccountTermAndPreClosure.java @@ -298,10 +298,10 @@ public DepositAccountTermAndPreClosure copy(BigDecimal depositAmount) { final DepositPreClosureDetail preClosureDetail = this.preClosureDetail.copy(); final DepositTermDetail depositTermDetail = this.depositTermDetail.copy(); final LocalDate expectedFirstDepositOnDate = null; - final Boolean transferInterestToLinkedAccount = false; + final Boolean transferInterestToLinkedAccount = this.transferInterestToLinkedAccount; - final DepositAccountOnClosureType accountOnClosureType = null; - final Long transferToSavingsId = null; + final DepositAccountOnClosureType accountOnClosureType = DepositAccountOnClosureType.fromInt(this.onAccountClosureType); + final Long transferToSavingsId = this.transferToSavingsAccountId; return DepositAccountTermAndPreClosure.createNew(preClosureDetail, depositTermDetail, account, actualDepositAmount, maturityAmount, maturityDate, depositPeriod, depositPeriodFrequency, expectedFirstDepositOnDate, accountOnClosureType, transferInterestToLinkedAccount, transferToSavingsId); @@ -326,4 +326,5 @@ public Integer getOnAccountClosureType() { public Long getTransferToSavingsAccountId() { return transferToSavingsAccountId; } + }