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 54edbcd0..b7ae112d 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 @@ -7,20 +7,20 @@ import net.codinux.banking.client.model.config.NoArgConstructor @NoArgConstructor open class BankAccount( val identifier: String, + val subAccountNumber: String? = null, + val iban: String? = null, + val productName: String? = null, var accountHolderName: String, val type: BankAccountType = BankAccountType.Other, - val iban: String? = null, - val subAccountNumber: String? = null, - val productName: String? = null, val currency: String = "EUR", var accountLimit: String? = null, -// var balance: BigDecimal = BigDecimal.ZERO, - var balance: Amount = Amount.Zero, // TODO: add a BigDecimal library - val isAccountTypeSupportedByApplication: Boolean = false, val features: Set = emptySet(), +// var balance: BigDecimal = BigDecimal.ZERO, + var balance: Amount = Amount.Zero, // TODO: add a BigDecimal library + val transactionsRetentionDays: Int? = null, open var lastTransactionsRetrievalTime: Instant? = null, var retrievedTransactionsFrom: 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 ed2cb485..e266ea57 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 @@ -129,9 +129,10 @@ open class FinTs4kMapper { protected open fun mapAccount(account: net.dankito.banking.client.model.BankAccount) = BankAccount( - account.identifier, account.accountHolderName, mapAccountType(account.type), account.iban, account.subAccountNumber, - account.productName, account.currency, account.accountLimit, mapAmount(account.balance), + account.identifier, account.subAccountNumber, account.iban, account.productName, account.accountHolderName, + mapAccountType(account.type), account.currency, account.accountLimit, account.isAccountTypeSupportedByApplication, mapFeatures(account), + mapAmount(account.balance), account.countDaysForWhichTransactionsAreKept, account.lastTransactionsRetrievalTime, account.retrievedTransactionsFrom, bookedTransactions = mapBookedTransactions(account).toMutableList()