diff --git a/fints4k/src/commonMain/kotlin/net/dankito/banking/fints/FinTsClient.kt b/fints4k/src/commonMain/kotlin/net/dankito/banking/fints/FinTsClient.kt index 8efc1477..1b001ce6 100644 --- a/fints4k/src/commonMain/kotlin/net/dankito/banking/fints/FinTsClient.kt +++ b/fints4k/src/commonMain/kotlin/net/dankito/banking/fints/FinTsClient.kt @@ -333,36 +333,35 @@ open class FinTsClient( val now = Date() val ninetyDaysAgo = Date(now.millisSinceEpoch - NinetyDaysMillis) - getTransactionsAsync(GetTransactionsParameter(account.supportsFeature(AccountFeature.RetrieveBalance), ninetyDaysAgo, abortIfTanIsRequired = true), bank, account) { response -> + getTransactionsAsync(GetTransactionsParameter(account, account.supportsFeature(AccountFeature.RetrieveBalance), ninetyDaysAgo, abortIfTanIsRequired = true), bank) { response -> callback(response) } } - open fun getTransactionsAsync(parameter: GetTransactionsParameter, bank: BankData, - account: AccountData, callback: (GetTransactionsResponse) -> Unit) { + open fun getTransactionsAsync(parameter: GetTransactionsParameter, bank: BankData, callback: (GetTransactionsResponse) -> Unit) { val dialogContext = DialogContext(bank, product) initDialog(dialogContext) { initDialogResponse -> if (initDialogResponse.successful == false) { - callback(GetTransactionsResponse(initDialogResponse, RetrievedAccountData.unsuccessfulList(account))) + callback(GetTransactionsResponse(initDialogResponse, RetrievedAccountData.unsuccessfulList(parameter.account))) } else { - mayGetBalance(parameter, account, dialogContext) { balanceResponse -> + mayGetBalance(parameter, dialogContext) { balanceResponse -> if (balanceResponse.successful == false && balanceResponse.couldCreateMessage == true) { // don't break here if required HKSAL message is not implemented closeDialog(dialogContext) - callback(GetTransactionsResponse(balanceResponse, RetrievedAccountData.unsuccessfulList(account))) + callback(GetTransactionsResponse(balanceResponse, RetrievedAccountData.unsuccessfulList(parameter.account))) } else { - getTransactionsAfterInitAndGetBalance(parameter, account, dialogContext, balanceResponse, callback) + getTransactionsAfterInitAndGetBalance(parameter, dialogContext, balanceResponse, callback) } } } } } - protected open fun getTransactionsAfterInitAndGetBalance(parameter: GetTransactionsParameter, account: AccountData, dialogContext: DialogContext, + protected open fun getTransactionsAfterInitAndGetBalance(parameter: GetTransactionsParameter, dialogContext: DialogContext, balanceResponse: Response, callback: (GetTransactionsResponse) -> Unit) { val balance: Money? = balanceResponse.getFirstSegmentById(InstituteSegmentId.Balance)?.let { Money(it.balance, it.currency) @@ -370,7 +369,7 @@ open class FinTsClient( val bookedTransactions = mutableSetOf() val unbookedTransactions = mutableSetOf() - val message = messageBuilder.createGetTransactionsMessage(parameter, account, dialogContext) + val message = messageBuilder.createGetTransactionsMessage(parameter, dialogContext) var remainingMt940String = "" @@ -378,7 +377,7 @@ open class FinTsClient( dialogContext.chunkedResponseHandler = { response -> response.getFirstSegmentById(InstituteSegmentId.AccountTransactionsMt940)?.let { transactionsSegment -> - val (chunkTransaction, remainder) = mt940Parser.parseTransactionsChunk(remainingMt940String + transactionsSegment.bookedTransactionsString, account) + val (chunkTransaction, remainder) = mt940Parser.parseTransactionsChunk(remainingMt940String + transactionsSegment.bookedTransactionsString, parameter.account) bookedTransactions.addAll(chunkTransaction) remainingMt940String = remainder @@ -392,15 +391,15 @@ open class FinTsClient( val successful = response.successful && (parameter.alsoRetrieveBalance == false || balance != null) - callback(GetTransactionsResponse(response, listOf(RetrievedAccountData(account, successful, balance, bookedTransactions, unbookedTransactions)), + callback(GetTransactionsResponse(response, listOf(RetrievedAccountData(parameter.account, successful, balance, bookedTransactions, unbookedTransactions)), if (parameter.maxCountEntries != null) parameter.isSettingMaxCountEntriesAllowedByBank else null )) } } - protected open fun mayGetBalance(parameter: GetTransactionsParameter, account: AccountData, dialogContext: DialogContext, callback: (Response) -> Unit) { - if (parameter.alsoRetrieveBalance && account.supportsFeature(AccountFeature.RetrieveBalance)) { - val message = messageBuilder.createGetBalanceMessage(account, dialogContext) + protected open fun mayGetBalance(parameter: GetTransactionsParameter, dialogContext: DialogContext, callback: (Response) -> Unit) { + if (parameter.alsoRetrieveBalance && parameter.account.supportsFeature(AccountFeature.RetrieveBalance)) { + val message = messageBuilder.createGetBalanceMessage(parameter.account, dialogContext) getAndHandleResponseForMessage(message, dialogContext) { response -> callback(response) diff --git a/fints4k/src/commonMain/kotlin/net/dankito/banking/fints/FinTsClientForCustomer.kt b/fints4k/src/commonMain/kotlin/net/dankito/banking/fints/FinTsClientForCustomer.kt index 978c7eaf..8180a53d 100644 --- a/fints4k/src/commonMain/kotlin/net/dankito/banking/fints/FinTsClientForCustomer.kt +++ b/fints4k/src/commonMain/kotlin/net/dankito/banking/fints/FinTsClientForCustomer.kt @@ -38,8 +38,8 @@ open class FinTsClientForCustomer( } - open fun getTransactionsAsync(parameter: GetTransactionsParameter, account: AccountData, callback: (GetTransactionsResponse) -> Unit) { - client.getTransactionsAsync(parameter, bank, account, callback) + open fun getTransactionsAsync(parameter: GetTransactionsParameter, callback: (GetTransactionsResponse) -> Unit) { + client.getTransactionsAsync(parameter, bank, callback) } diff --git a/fints4k/src/commonMain/kotlin/net/dankito/banking/fints/messages/MessageBuilder.kt b/fints4k/src/commonMain/kotlin/net/dankito/banking/fints/messages/MessageBuilder.kt index 53d2fd2b..5b048bcb 100644 --- a/fints4k/src/commonMain/kotlin/net/dankito/banking/fints/messages/MessageBuilder.kt +++ b/fints4k/src/commonMain/kotlin/net/dankito/banking/fints/messages/MessageBuilder.kt @@ -146,28 +146,27 @@ open class MessageBuilder(protected val generator: ISegmentNumberGenerator = Seg } - open fun createGetTransactionsMessage(parameter: GetTransactionsParameter, account: AccountData, - dialogContext: DialogContext): MessageBuilderResult { + open fun createGetTransactionsMessage(parameter: GetTransactionsParameter, dialogContext: DialogContext): MessageBuilderResult { - val result = supportsGetTransactionsMt940(account) + val result = supportsGetTransactionsMt940(parameter.account) if (result.isJobVersionSupported) { - return createGetTransactionsMessageMt940(result, parameter, dialogContext, account) + return createGetTransactionsMessageMt940(result, parameter, dialogContext) } return result } protected open fun createGetTransactionsMessageMt940(result: MessageBuilderResult, parameter: GetTransactionsParameter, - dialogContext: DialogContext, account: AccountData): MessageBuilderResult { + dialogContext: DialogContext): MessageBuilderResult { if (parameter.maxCountEntries != null) { parameter.isSettingMaxCountEntriesAllowedByBank = determineIsSettingMaxCountEntriesAllowed(dialogContext.bank, InstituteSegmentId.AccountTransactionsMt940Parameters, listOf(5, 6, 7)) } - val transactionsJob = if (result.isAllowed(7)) KontoumsaetzeZeitraumMt940Version7(generator.resetSegmentNumber(2), parameter, dialogContext.bank, account) - else if (result.isAllowed(6)) KontoumsaetzeZeitraumMt940Version6(generator.resetSegmentNumber(2), parameter, account) - else KontoumsaetzeZeitraumMt940Version5(generator.resetSegmentNumber(2), parameter, account) + val transactionsJob = if (result.isAllowed(7)) KontoumsaetzeZeitraumMt940Version7(generator.resetSegmentNumber(2), parameter, dialogContext.bank) + else if (result.isAllowed(6)) KontoumsaetzeZeitraumMt940Version6(generator.resetSegmentNumber(2), parameter) + else KontoumsaetzeZeitraumMt940Version5(generator.resetSegmentNumber(2), parameter) val segments = mutableListOf(transactionsJob) diff --git a/fints4k/src/commonMain/kotlin/net/dankito/banking/fints/messages/segmente/implementierte/umsaetze/KontoumsaetzeZeitraumMt940Version5.kt b/fints4k/src/commonMain/kotlin/net/dankito/banking/fints/messages/segmente/implementierte/umsaetze/KontoumsaetzeZeitraumMt940Version5.kt index e1c12df4..d217b8c9 100644 --- a/fints4k/src/commonMain/kotlin/net/dankito/banking/fints/messages/segmente/implementierte/umsaetze/KontoumsaetzeZeitraumMt940Version5.kt +++ b/fints4k/src/commonMain/kotlin/net/dankito/banking/fints/messages/segmente/implementierte/umsaetze/KontoumsaetzeZeitraumMt940Version5.kt @@ -17,7 +17,5 @@ import net.dankito.banking.fints.model.GetTransactionsParameter */ open class KontoumsaetzeZeitraumMt940Version5( segmentNumber: Int, - parameter: GetTransactionsParameter, - account: AccountData -) - : KontoumsaetzeZeitraumMt940Base(5, segmentNumber, Kontoverbindung(account), parameter) \ No newline at end of file + parameter: GetTransactionsParameter +) : KontoumsaetzeZeitraumMt940Base(5, segmentNumber, Kontoverbindung(parameter.account), parameter) \ No newline at end of file diff --git a/fints4k/src/commonMain/kotlin/net/dankito/banking/fints/messages/segmente/implementierte/umsaetze/KontoumsaetzeZeitraumMt940Version6.kt b/fints4k/src/commonMain/kotlin/net/dankito/banking/fints/messages/segmente/implementierte/umsaetze/KontoumsaetzeZeitraumMt940Version6.kt index a5418503..3e7fe93b 100644 --- a/fints4k/src/commonMain/kotlin/net/dankito/banking/fints/messages/segmente/implementierte/umsaetze/KontoumsaetzeZeitraumMt940Version6.kt +++ b/fints4k/src/commonMain/kotlin/net/dankito/banking/fints/messages/segmente/implementierte/umsaetze/KontoumsaetzeZeitraumMt940Version6.kt @@ -17,8 +17,6 @@ import net.dankito.banking.fints.model.GetTransactionsParameter */ open class KontoumsaetzeZeitraumMt940Version6( segmentNumber: Int, - parameter: GetTransactionsParameter, - account: AccountData + parameter: GetTransactionsParameter -) - : KontoumsaetzeZeitraumMt940Base(6, segmentNumber, Kontoverbindung(account), parameter) \ No newline at end of file +) : KontoumsaetzeZeitraumMt940Base(6, segmentNumber, Kontoverbindung(parameter.account), parameter) \ No newline at end of file diff --git a/fints4k/src/commonMain/kotlin/net/dankito/banking/fints/messages/segmente/implementierte/umsaetze/KontoumsaetzeZeitraumMt940Version7.kt b/fints4k/src/commonMain/kotlin/net/dankito/banking/fints/messages/segmente/implementierte/umsaetze/KontoumsaetzeZeitraumMt940Version7.kt index 8ef40140..c7aed1f7 100644 --- a/fints4k/src/commonMain/kotlin/net/dankito/banking/fints/messages/segmente/implementierte/umsaetze/KontoumsaetzeZeitraumMt940Version7.kt +++ b/fints4k/src/commonMain/kotlin/net/dankito/banking/fints/messages/segmente/implementierte/umsaetze/KontoumsaetzeZeitraumMt940Version7.kt @@ -19,7 +19,5 @@ import net.dankito.banking.fints.model.GetTransactionsParameter open class KontoumsaetzeZeitraumMt940Version7( segmentNumber: Int, parameter: GetTransactionsParameter, - bank: BankData, - account: AccountData -) - : KontoumsaetzeZeitraumMt940Base(7, segmentNumber, KontoverbindungInternational(account, bank), parameter) \ No newline at end of file + bank: BankData +) : KontoumsaetzeZeitraumMt940Base(7, segmentNumber, KontoverbindungInternational(parameter.account, bank), parameter) \ No newline at end of file diff --git a/fints4k/src/commonMain/kotlin/net/dankito/banking/fints/model/GetTransactionsParameter.kt b/fints4k/src/commonMain/kotlin/net/dankito/banking/fints/model/GetTransactionsParameter.kt index 343f432d..3567c568 100644 --- a/fints4k/src/commonMain/kotlin/net/dankito/banking/fints/model/GetTransactionsParameter.kt +++ b/fints4k/src/commonMain/kotlin/net/dankito/banking/fints/model/GetTransactionsParameter.kt @@ -1,9 +1,11 @@ package net.dankito.banking.fints.model import net.dankito.utils.multiplatform.Date +import kotlin.jvm.JvmOverloads -open class GetTransactionsParameter( +open class GetTransactionsParameter @JvmOverloads constructor( + open val account: AccountData, open val alsoRetrieveBalance: Boolean = true, open val fromDate: Date? = null, open val toDate: Date? = null, @@ -12,8 +14,6 @@ open class GetTransactionsParameter( * Be aware this is by far not supported by all banks. * * And it depends on the actual job if setting maxCountEntries is supported or not. - * - * // TODO: set a parameter in response if maxCountEntries is set but bank doesn't support it. */ open val maxCountEntries: Int? = null, open val abortIfTanIsRequired: Boolean = false, diff --git a/fints4k/src/commonTest/kotlin/net/dankito/banking/fints/messages/MessageBuilderTest.kt b/fints4k/src/commonTest/kotlin/net/dankito/banking/fints/messages/MessageBuilderTest.kt index d7d8c38c..efd34a77 100644 --- a/fints4k/src/commonTest/kotlin/net/dankito/banking/fints/messages/MessageBuilderTest.kt +++ b/fints4k/src/commonTest/kotlin/net/dankito/banking/fints/messages/MessageBuilderTest.kt @@ -128,7 +128,7 @@ class MessageBuilderTest : FinTsTestBase() { val dialogContext = DialogContext(Bank, Product) // when - val result = underTest.createGetTransactionsMessage(GetTransactionsParameter(), Account, dialogContext) + val result = underTest.createGetTransactionsMessage(GetTransactionsParameter(Account), dialogContext) // then expect(result.isJobAllowed).toBe(false) @@ -146,7 +146,7 @@ class MessageBuilderTest : FinTsTestBase() { val dialogContext = DialogContext(Bank, Product) // when - val result = underTest.createGetTransactionsMessage(GetTransactionsParameter(), account, dialogContext) + val result = underTest.createGetTransactionsMessage(GetTransactionsParameter(account), dialogContext) // then expect(result.isJobAllowed).toBe(true) @@ -168,7 +168,7 @@ class MessageBuilderTest : FinTsTestBase() { val maxCountEntries = 99 // when - val result = underTest.createGetTransactionsMessage(GetTransactionsParameter(false, fromDate, toDate, maxCountEntries), account, dialogContext) + val result = underTest.createGetTransactionsMessage(GetTransactionsParameter(account, false, fromDate, toDate, maxCountEntries), dialogContext) // then expect(result.createdMessage).notToBeNull() @@ -200,7 +200,7 @@ class MessageBuilderTest : FinTsTestBase() { val continuationId = "9345-10-26-11.52.15.693455" // when - val result = underTest.createGetTransactionsMessage(GetTransactionsParameter(false, fromDate, toDate, maxCountEntries, false), account, dialogContext) // TODO: test Aufsetzpunkt / continuationId + val result = underTest.createGetTransactionsMessage(GetTransactionsParameter(account, false, fromDate, toDate, maxCountEntries, false), dialogContext) // TODO: test Aufsetzpunkt / continuationId // then expect(result.createdMessage).notToBeNull() diff --git a/ui/BankingUiCommon/src/commonMain/kotlin/net/dankito/banking/ui/IBankingClient.kt b/ui/BankingUiCommon/src/commonMain/kotlin/net/dankito/banking/ui/IBankingClient.kt index eb7adf65..e512d42d 100644 --- a/ui/BankingUiCommon/src/commonMain/kotlin/net/dankito/banking/ui/IBankingClient.kt +++ b/ui/BankingUiCommon/src/commonMain/kotlin/net/dankito/banking/ui/IBankingClient.kt @@ -16,7 +16,6 @@ interface IBankingClient { fun addAccountAsync(callback: (AddAccountResponse) -> Unit) fun getTransactionsAsync( - bankAccount: TypedBankAccount, parameter: GetTransactionsParameter, callback: (GetTransactionsResponse) -> Unit ) diff --git a/ui/BankingUiCommon/src/commonMain/kotlin/net/dankito/banking/ui/model/parameters/GetTransactionsParameter.kt b/ui/BankingUiCommon/src/commonMain/kotlin/net/dankito/banking/ui/model/parameters/GetTransactionsParameter.kt index 0f6f8aa4..2e484336 100644 --- a/ui/BankingUiCommon/src/commonMain/kotlin/net/dankito/banking/ui/model/parameters/GetTransactionsParameter.kt +++ b/ui/BankingUiCommon/src/commonMain/kotlin/net/dankito/banking/ui/model/parameters/GetTransactionsParameter.kt @@ -2,16 +2,15 @@ package net.dankito.banking.ui.model.parameters import net.dankito.utils.multiplatform.Date import net.dankito.banking.ui.model.IAccountTransaction +import net.dankito.banking.ui.model.TypedBankAccount +import kotlin.jvm.JvmOverloads -open class GetTransactionsParameter( - val alsoRetrieveBalance: Boolean = true, - val fromDate: Date? = null, - val toDate: Date? = null, - val abortIfTanIsRequired: Boolean = false, - val retrievedChunkListener: ((List) -> Unit)? = null -) { - - constructor() : this(true, null, null) // for Java - -} \ No newline at end of file +open class GetTransactionsParameter @JvmOverloads constructor( + open val account: TypedBankAccount, + open val alsoRetrieveBalance: Boolean = true, + open val fromDate: Date? = null, + open val toDate: Date? = null, + open val abortIfTanIsRequired: Boolean = false, + open val retrievedChunkListener: ((List) -> Unit)? = null +) \ No newline at end of file diff --git a/ui/BankingUiCommon/src/commonMain/kotlin/net/dankito/banking/ui/presenter/BankingPresenter.kt b/ui/BankingUiCommon/src/commonMain/kotlin/net/dankito/banking/ui/presenter/BankingPresenter.kt index 7b1973a4..6d0ab40a 100644 --- a/ui/BankingUiCommon/src/commonMain/kotlin/net/dankito/banking/ui/presenter/BankingPresenter.kt +++ b/ui/BankingUiCommon/src/commonMain/kotlin/net/dankito/banking/ui/presenter/BankingPresenter.kt @@ -279,13 +279,13 @@ open class BankingPresenter( fetchAccountTransactionsAsync(bankAccount, null, false, callback) } - open fun fetchAccountTransactionsAsync(bankAccount: TypedBankAccount, fromDate: Date?, abortIfTanIsRequired: Boolean = false, + open fun fetchAccountTransactionsAsync(account: TypedBankAccount, fromDate: Date?, abortIfTanIsRequired: Boolean = false, callback: ((GetTransactionsResponse) -> Unit)? = null) { - getBankingClientForAccount(bankAccount.customer)?.let { client -> + getBankingClientForAccount(account.customer)?.let { client -> val startDate = Date() - client.getTransactionsAsync(bankAccount, GetTransactionsParameter(true, fromDate, null, abortIfTanIsRequired, { receivedAccountsTransactionChunk(bankAccount, it) } )) { response -> + client.getTransactionsAsync(GetTransactionsParameter(account,true, fromDate, null, abortIfTanIsRequired, { receivedAccountsTransactionChunk(account, it) } )) { response -> if (response.tanRequiredButWeWereToldToAbortIfSo == false) { // don't call retrievedAccountTransactions() if aborted due to TAN required but we told client to abort if so retrievedAccountTransactions(response, startDate, fromDate == null) diff --git a/ui/fints4kBankingClient/src/commonMain/kotlin/net/dankito/banking/fints4kBankingClient.kt b/ui/fints4kBankingClient/src/commonMain/kotlin/net/dankito/banking/fints4kBankingClient.kt index 2d78f2b3..3089819d 100644 --- a/ui/fints4kBankingClient/src/commonMain/kotlin/net/dankito/banking/fints4kBankingClient.kt +++ b/ui/fints4kBankingClient/src/commonMain/kotlin/net/dankito/banking/fints4kBankingClient.kt @@ -75,25 +75,27 @@ open class fints4kBankingClient( } - override fun getTransactionsAsync(bankAccount: TypedBankAccount, parameter: GetTransactionsParameter, callback: (GetTransactionsResponse) -> Unit) { + override fun getTransactionsAsync(parameter: GetTransactionsParameter, callback: (GetTransactionsResponse) -> Unit) { + val bankAccount = parameter.account + findAccountForBankAccount(bankAccount) { account, errorMessage -> if (account == null) { callback(GetTransactionsResponse(bankAccount, errorMessage ?: "")) } else { - val mappedParameter = GetTransactionsParameter(parameter.alsoRetrieveBalance, parameter.fromDate, + val mappedParameter = GetTransactionsParameter(account, parameter.alsoRetrieveBalance, parameter.fromDate, parameter.toDate, null, parameter.abortIfTanIsRequired) { parameter.retrievedChunkListener?.invoke(mapper.mapTransactions(bankAccount, it)) } - doGetTransactionsAsync(mappedParameter, account, bankAccount, callback) + doGetTransactionsAsync(mappedParameter, bankAccount, callback) } } } protected open fun doGetTransactionsAsync(parameter: net.dankito.banking.fints.model.GetTransactionsParameter, - account: AccountData, bankAccount: TypedBankAccount, callback: (GetTransactionsResponse) -> Unit) { - client.getTransactionsAsync(parameter, account) { response -> + bankAccount: TypedBankAccount, callback: (GetTransactionsResponse) -> Unit) { + client.getTransactionsAsync(parameter) { response -> handleGetTransactionsResponse(bankAccount, response, callback) } } diff --git a/ui/hbci4jBankingClient/src/main/kotlin/net/dankito/banking/hbci4jBankingClient.kt b/ui/hbci4jBankingClient/src/main/kotlin/net/dankito/banking/hbci4jBankingClient.kt index f887edb9..1d017bf4 100644 --- a/ui/hbci4jBankingClient/src/main/kotlin/net/dankito/banking/hbci4jBankingClient.kt +++ b/ui/hbci4jBankingClient/src/main/kotlin/net/dankito/banking/hbci4jBankingClient.kt @@ -133,21 +133,22 @@ open class hbci4jBankingClient( open fun getTransactionsOfLast90Days(bankAccount: TypedBankAccount): GetTransactionsResponse { val ninetyDaysAgo = Date(Date().time - NinetyDaysInMilliseconds) - return getTransactions(bankAccount, GetTransactionsParameter(bankAccount.supportsRetrievingBalance, ninetyDaysAgo)) // TODO: implement abortIfTanIsRequired + return getTransactions(GetTransactionsParameter(bankAccount, bankAccount.supportsRetrievingBalance, ninetyDaysAgo)) // TODO: implement abortIfTanIsRequired } - override fun getTransactionsAsync(bankAccount: TypedBankAccount, parameter: GetTransactionsParameter, callback: (GetTransactionsResponse) -> Unit) { + override fun getTransactionsAsync(parameter: GetTransactionsParameter, callback: (GetTransactionsResponse) -> Unit) { asyncRunner.runAsync { - callback(getTransactions(bankAccount, parameter)) + callback(getTransactions(parameter)) } } - protected open fun getTransactions(account: TypedBankAccount, parameter: GetTransactionsParameter): GetTransactionsResponse { + protected open fun getTransactions(parameter: GetTransactionsParameter): GetTransactionsResponse { val connection = connect() + val account = parameter.account connection.handle?.let { handle -> try { - val (nullableBalanceJob, accountTransactionsJob, status) = executeJobsForGetAccountingEntries(handle, account, parameter) + val (nullableBalanceJob, accountTransactionsJob, status) = executeJobsForGetAccountingEntries(handle, parameter) // Pruefen, ob die Kommunikation mit der Bank grundsaetzlich geklappt hat if (!status.isOK) { @@ -195,8 +196,8 @@ open class hbci4jBankingClient( return GetTransactionsResponse(account, connection.error?.getInnerExceptionMessage() ?: "Could not connect") } - protected open fun executeJobsForGetAccountingEntries(handle: HBCIHandler, bankAccount: TypedBankAccount, parameter: GetTransactionsParameter): Triple { - val konto = mapper.mapToKonto(bankAccount) + protected open fun executeJobsForGetAccountingEntries(handle: HBCIHandler, parameter: GetTransactionsParameter): Triple { + val konto = mapper.mapToKonto(parameter.account) // 1. Auftrag fuer das Abrufen des Saldos erzeugen var balanceJob: HBCIJob? = null