From 9512db34025acdbb0dcf758a876826e176da86d9 Mon Sep 17 00:00:00 2001 From: dankito Date: Thu, 5 Sep 2024 22:14:01 +0200 Subject: [PATCH] Renamed unbooked- to prebookedTransactions --- .../kotlin/net/codinux/banking/client/model/BankAccount.kt | 2 +- ...edAccountTransaction.kt => PrebookedAccountTransaction.kt} | 2 +- .../banking/client/model/response/GetTransactionsResponse.kt | 4 ++-- .../net/codinux/banking/client/fints4k/FinTs4kMapper.kt | 3 +-- 4 files changed, 5 insertions(+), 6 deletions(-) rename BankingClientModel/src/commonMain/kotlin/net/codinux/banking/client/model/{UnbookedAccountTransaction.kt => PrebookedAccountTransaction.kt} (74%) diff --git a/BankingClientModel/src/commonMain/kotlin/net/codinux/banking/client/model/BankAccount.kt b/BankingClientModel/src/commonMain/kotlin/net/codinux/banking/client/model/BankAccount.kt index ce20953e..54edbcd0 100644 --- a/BankingClientModel/src/commonMain/kotlin/net/codinux/banking/client/model/BankAccount.kt +++ b/BankingClientModel/src/commonMain/kotlin/net/codinux/banking/client/model/BankAccount.kt @@ -26,7 +26,7 @@ open class BankAccount( var retrievedTransactionsFrom: LocalDate? = null, open val bookedTransactions: MutableList = mutableListOf(), - open val unbookedTransactions: MutableList = mutableListOf(), + open val prebookedTransactions: MutableList = mutableListOf(), var userSetDisplayName: String? = null, var displayIndex: Int = 0, diff --git a/BankingClientModel/src/commonMain/kotlin/net/codinux/banking/client/model/UnbookedAccountTransaction.kt b/BankingClientModel/src/commonMain/kotlin/net/codinux/banking/client/model/PrebookedAccountTransaction.kt similarity index 74% rename from BankingClientModel/src/commonMain/kotlin/net/codinux/banking/client/model/UnbookedAccountTransaction.kt rename to BankingClientModel/src/commonMain/kotlin/net/codinux/banking/client/model/PrebookedAccountTransaction.kt index 7e8905f4..470d3b51 100644 --- a/BankingClientModel/src/commonMain/kotlin/net/codinux/banking/client/model/UnbookedAccountTransaction.kt +++ b/BankingClientModel/src/commonMain/kotlin/net/codinux/banking/client/model/PrebookedAccountTransaction.kt @@ -3,5 +3,5 @@ package net.codinux.banking.client.model import net.codinux.banking.client.model.config.NoArgConstructor @NoArgConstructor -open class UnbookedAccountTransaction { +open class PrebookedAccountTransaction { } \ No newline at end of file diff --git a/BankingClientModel/src/commonMain/kotlin/net/codinux/banking/client/model/response/GetTransactionsResponse.kt b/BankingClientModel/src/commonMain/kotlin/net/codinux/banking/client/model/response/GetTransactionsResponse.kt index 8dbc109e..d274e261 100644 --- a/BankingClientModel/src/commonMain/kotlin/net/codinux/banking/client/model/response/GetTransactionsResponse.kt +++ b/BankingClientModel/src/commonMain/kotlin/net/codinux/banking/client/model/response/GetTransactionsResponse.kt @@ -5,7 +5,7 @@ import kotlinx.datetime.LocalDate import net.codinux.banking.client.model.AccountTransaction import net.codinux.banking.client.model.Amount import net.codinux.banking.client.model.BankAccount -import net.codinux.banking.client.model.UnbookedAccountTransaction +import net.codinux.banking.client.model.PrebookedAccountTransaction import net.codinux.banking.client.model.config.NoArgConstructor @NoArgConstructor @@ -13,7 +13,7 @@ open class GetTransactionsResponse( val account: BankAccount, val balance: Amount? = null, val bookedTransactions: List, - val unbookedTransactions: List, + val prebookedTransactions: List, val transactionsRetrievalTime: Instant, val retrievedTransactionsFrom: LocalDate? = null, val retrievedTransactionsTo: LocalDate? = null diff --git a/FinTs4jBankingClient/src/commonMain/kotlin/net/codinux/banking/client/fints4k/FinTs4kMapper.kt b/FinTs4jBankingClient/src/commonMain/kotlin/net/codinux/banking/client/fints4k/FinTs4kMapper.kt index 60ed58c1..ed2cb485 100644 --- a/FinTs4jBankingClient/src/commonMain/kotlin/net/codinux/banking/client/fints4k/FinTs4kMapper.kt +++ b/FinTs4jBankingClient/src/commonMain/kotlin/net/codinux/banking/client/fints4k/FinTs4kMapper.kt @@ -132,9 +132,8 @@ open class FinTs4kMapper { account.identifier, account.accountHolderName, mapAccountType(account.type), account.iban, account.subAccountNumber, account.productName, account.currency, account.accountLimit, mapAmount(account.balance), account.isAccountTypeSupportedByApplication, mapFeatures(account), + account.countDaysForWhichTransactionsAreKept, account.lastTransactionsRetrievalTime, account.retrievedTransactionsFrom, - // TODO: map haveAllTransactionsBeenRetrieved - countDaysForWhichTransactionsAreKept = account.countDaysForWhichTransactionsAreKept, bookedTransactions = mapBookedTransactions(account).toMutableList() )