Adam Saghy created FINERACT-2274:
------------------------------------
Summary: Rework LoanAccrualsProcessingServiceImpl to not use
loan.getLoanTransactions()
Key: FINERACT-2274
URL: https://issues.apache.org/jira/browse/FINERACT-2274
Project: Apache Fineract
Issue Type: Sub-task
Reporter: Adam Saghy
org.apache.fineract.portfolio.loanaccount.service.LoanAccrualsProcessingServiceImpl#addAccruals(org.apache.fineract.portfolio.loanaccount.domain.Loan,
java.time.LocalDate, boolean, boolean, boolean, boolean) method are fetching
all the existing accrual transactions of the loan.
*We should rework this logic and make sure we are not fetching something that
is not absolutely necessary!*
#
org.apache.fineract.portfolio.loanaccount.service.LoanAccrualsProcessingServiceImpl#reverseTransactionsAfter
** Make sure we dont use loan.getLoanTransactions() rather lets fetch the
transactions based on the date and reversal status explicitly!
#
org.apache.fineract.portfolio.loanaccount.service.LoanAccrualsProcessingServiceImpl#ensureAccrualTransactionMappings
** Make sure we dont use loan.getLoanTransactions() rather lets fetch
LoanChargePaidBy based on the date, the reversal status and loan charge paid by
details explicitly!
#
org.apache.fineract.portfolio.loanaccount.service.LoanAccrualsProcessingServiceImpl#calcInterestAccruedAmount
** Make sure we dont use loan.getLoanTransactions() rather lets fetch the
aggregated amount of Accrual and Accrual adjustments for interest!
#
org.apache.fineract.portfolio.loanaccount.service.LoanAccrualsProcessingServiceImpl#calcChargeAccruedAmount
** Make sure we dont use loan.getLoanTransactions() rather lets fetch the
aggregated amount of Accrual and Accrual adjustments for charges! (1 query for
3rd and 4th might be even better!)
#
org.apache.fineract.portfolio.loanaccount.service.LoanAccrualsProcessingServiceImpl#calcInterestUnrecognizedWaivedAmount
** Make sure we dont use loan.getLoanTransactions() rather lets fetch the
transactions based on the date and reversal status explicitly!
#
org.apache.fineract.portfolio.loanaccount.service.LoanAccrualsProcessingServiceImpl#createIncomePostingAndAccrualTransactionOnLoanClosure
** Make sure we only set the loan on the new loan transaction, but we dont
call loan.getLoanTransactions() or loan.addLoanTransaction()
#
org.apache.fineract.portfolio.loanaccount.service.LoanAccrualsProcessingServiceImpl#addAccrualTransaction
** Make sure we only set the loan on the new loan transaction, but we dont
call loan.getLoanTransactions() or loan.addLoanTransaction()
#
org.apache.fineract.portfolio.loanaccount.service.LoanAccrualsProcessingServiceImpl#reprocessNonPeriodicAccruals
** Make sure we only set the loan on the new loan transaction, but we dont
call loan.getLoanTransactions() or loan.addLoanTransaction()
#
org.apache.fineract.portfolio.loanaccount.service.LoanAccrualsProcessingServiceImpl#createUpdateIncomePostingTransaction
** Make sure we only set the loan on the new loan transaction, but we dont
call loan.getLoanTransactions() or loan.addLoanTransaction()
#
org.apache.fineract.portfolio.loanaccount.service.LoanAccrualsProcessingServiceImpl#createUpdateAccrualTransaction
** Make sure we only set the loan on the new loan transaction, but we dont
call loan.getLoanTransactions() or loan.addLoanTransaction()
#
org.apache.fineract.portfolio.loanaccount.service.LoanAccrualsProcessingServiceImpl#createAccrualTransactionAndUpdateChargesPaidBy
** Make sure we only set the loan on the new loan transaction, but we dont
call loan.getLoanTransactions() or loan.addLoanTransaction()
--
This message was sent by Atlassian Jira
(v8.20.10#820010)