FINERACT-2327: when Interest Refund was created manually, we should only return the newly created Interest Refund transaction identifiers in the result.

This commit is contained in:
Attila Budai
2025-08-21 11:10:51 +02:00
committed by Adam Saghy
parent 6c875fa6c6
commit 8fe9dbc614
4 changed files with 255 additions and 6 deletions
@@ -309,8 +309,7 @@ public class EventCheckHelper {
Response<PostLoansLoanIdTransactionsResponse> transactionResponse, TransactionType transactionType, String externalOwnerId)
throws IOException {
Long loanId = transactionResponse.body().getLoanId();
Long transactionId = transactionType.equals(TransactionType.INTEREST_REFUND) ? transactionResponse.body().getSubResourceId()
: transactionResponse.body().getResourceId();
Long transactionId = transactionResponse.body().getResourceId();
Response<GetLoansLoanIdResponse> loanDetailsResponse = loansApi.retrieveLoan(loanId, false, "transactions", "", "").execute();
List<GetLoansLoanIdTransactions> transactions = loanDetailsResponse.body().getTransactions();
GetLoansLoanIdTransactions transactionFound = transactions//