FINERACT-2081: clear closed_on date on repayment reversal
This commit is contained in:
committed by
Adam Saghy
parent
69dd19c74b
commit
c70007e30a
+14
@@ -49,6 +49,20 @@ public class DefaultLoanLifecycleStateMachine implements LoanLifecycleStateMachi
|
||||
// in case of Loan creation, a LoanCreatedBusinessEvent is also raised, no need to send a status change
|
||||
businessEventNotifierService.notifyPostBusinessEvent(new LoanStatusChangedBusinessEvent(loan));
|
||||
}
|
||||
|
||||
// set mandatory field states based on new status after the transition
|
||||
switch (newStatus) {
|
||||
case ACTIVE -> {
|
||||
if (loan.getClosedOnDate() != null) {
|
||||
loan.setClosedOnDate(null);
|
||||
}
|
||||
if (loan.getOverpaidOnDate() != null) {
|
||||
loan.setOverpaidOnDate(null);
|
||||
}
|
||||
}
|
||||
default -> {
|
||||
}
|
||||
}
|
||||
}
|
||||
}
|
||||
|
||||
|
||||
Reference in New Issue
Block a user