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


##########
fineract-provider/src/main/java/org/apache/fineract/portfolio/loanaccount/service/LoanApplicationWritePlatformServiceJpaRepositoryImpl.java:
##########
@@ -1705,4 +1709,20 @@ private void officeSpecificLoanProductValidation(final 
Long productId, final Lon
         }
     }
 
+    private void validateTransactionProcessingStrategy(final LoanProduct 
loanProduct, final String loanRepaymentStrategy) {
+        if 
(loanProduct.getRepaymentStrategy().equals(LoanProductConstants.ADVANCED_PAYMENT_ALLOCATION_STRATEGY))
 {

Review Comment:
   This one is not necessary true.
   
   Just because the loan product was configured to advanced payment allocation, 
it does not mean the loan must be as well.
   
   The rule is:
   - If the loan product WAS NOT configured for advanced payment allocation, 
the loan CANNOT be 'advanced payment allocation`
   - If the loan product WAS configured for advanced payment allocation, the 
loan CAN be advanced payment allocation OR ANYTHING ELSE, but if something else 
is selected the loan schedule type MUST be Cumulative.
   - When the loan schedule type is CUMULATIVE, then Loan and loan product 
repayment strategy CANNOT be "advanced payment allocation". 
   - When the loan schedule type is PROGRESSIVE, then the loan and loan product 
repayment strategy MUST be only "advanced payment allocation".
   
   I hope it helps!



-- 
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