adamsaghy commented on code in PR #5041:
URL: https://github.com/apache/fineract/pull/5041#discussion_r2375682440
##########
fineract-provider/src/main/java/org/apache/fineract/portfolio/loanaccount/service/LoanTransactionProcessingServiceImpl.java:
##########
@@ -148,21 +149,22 @@ private Loan getLoan(List<LoanTransaction>
loanTransactions, List<LoanRepaymentS
@Override
public ChangedTransactionDetail reprocessLoanTransactions(String
transactionProcessingStrategyCode, LocalDate disbursementDate,
- List<LoanTransaction> loanTransactions, MonetaryCurrency currency,
List<LoanRepaymentScheduleInstallment> installments,
- Set<LoanCharge> charges) {
+ List<LoanTransaction> loanTransactionsToReprocess,
MonetaryCurrency currency,
+ List<LoanRepaymentScheduleInstallment> installments,
Set<LoanCharge> charges, List<LoanTransaction> loanTransactions) {
final LoanRepaymentScheduleTransactionProcessor
loanRepaymentScheduleTransactionProcessor = getTransactionProcessor(
transactionProcessingStrategyCode);
if (loanRepaymentScheduleTransactionProcessor instanceof
AdvancedPaymentScheduleTransactionProcessor advancedProcessor) {
LocalDate currentDate = DateUtils.getBusinessLocalDate();
Pair<ChangedTransactionDetail,
ProgressiveLoanInterestScheduleModel> result = advancedProcessor
- .reprocessProgressiveLoanTransactions(disbursementDate,
currentDate, loanTransactions, currency, installments, charges);
+ .reprocessProgressiveLoanTransactions(disbursementDate,
currentDate, loanTransactionsToReprocess, currency,
+ installments, charges, loanTransactions);
if
(!TransactionSynchronizationManager.isCurrentTransactionReadOnly()) {
-
modelRepository.writeInterestScheduleModel(getLoan(loanTransactions,
installments, charges), result.getRight());
+
modelRepository.writeInterestScheduleModel(getLoan(loanTransactionsToReprocess,
installments, charges), result.getRight());
}
return result.getLeft();
} else {
- return
loanRepaymentScheduleTransactionProcessor.reprocessLoanTransactions(disbursementDate,
loanTransactions, currency,
- installments, charges);
+ return
loanRepaymentScheduleTransactionProcessor.reprocessLoanTransactions(disbursementDate,
loanTransactionsToReprocess,
Review Comment:
what is the difference between `loanTransactionsToReprocess` and
`loanTransactions` and why to provide both?
--
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]