taskain7 commented on code in PR #2759:
URL: https://github.com/apache/fineract/pull/2759#discussion_r1033044966


##########
fineract-provider/src/main/java/org/apache/fineract/cob/loan/AbstractLoanItemProcessor.java:
##########
@@ -40,17 +42,25 @@ public abstract class AbstractLoanItemProcessor implements 
ItemProcessor<Loan, L
 
     @Setter(AccessLevel.PROTECTED)
     private ExecutionContext executionContext;
+    private LocalDate businessDate;
 
     @Override
     public Loan process(@NotNull Loan item) throws Exception {
         TreeMap<Long, String> businessStepMap = (TreeMap<Long, String>) 
executionContext.get(LoanCOBConstant.BUSINESS_STEP_MAP);
 
-        return cobBusinessStepService.run(businessStepMap, item);
+        Loan alreadyProcessedLoan = 
cobBusinessStepService.run(businessStepMap, item);
+        alreadyProcessedLoan.setLastClosedBusinessDate(businessDate);
+        return alreadyProcessedLoan;
     }
 
     @AfterStep
     public ExitStatus afterStep(@NotNull StepExecution stepExecution) {
         return ExitStatus.COMPLETED;
     }
 
+    protected void setBusinessDate(StepExecution stepExecution) {

Review Comment:
   we need this when tha business date is in different ExecutionContext than 
the other parameters we use (i.e. LoanCOB)



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