From 68fd3f2188cb2c56ac61dcd15a8896d5969838af Mon Sep 17 00:00:00 2001 From: dankito Date: Mon, 10 Aug 2020 16:35:47 +0200 Subject: [PATCH] Fixed showing "Fetch all transaction" below list (but cell has white spaces, why?) --- .../ui/views/AccountTransactionsDialog.swift | 29 +++++++++++-------- 1 file changed, 17 insertions(+), 12 deletions(-) diff --git a/ui/BankingiOSApp/BankingiOSApp/ui/views/AccountTransactionsDialog.swift b/ui/BankingiOSApp/BankingiOSApp/ui/views/AccountTransactionsDialog.swift index 441894e9..d4da9efe 100644 --- a/ui/BankingiOSApp/BankingiOSApp/ui/views/AccountTransactionsDialog.swift +++ b/ui/BankingiOSApp/BankingiOSApp/ui/views/AccountTransactionsDialog.swift @@ -95,26 +95,31 @@ struct AccountTransactionsDialog: View { Spacer() - List { - ForEach(filteredTransactions.sorted(by: { $0.valueDate.date > $1.valueDate.date } ), id: \.technicalId) { transaction in - AccountTransactionListItem(transaction, self.areMoreThanOneBanksTransactionsDisplayed) + Form { + Section { + ForEach(filteredTransactions.sorted(by: { $0.valueDate.date > $1.valueDate.date } ), id: \.technicalId) { transaction in + AccountTransactionListItem(transaction, self.areMoreThanOneBanksTransactionsDisplayed) + } } if haveAllTransactionsBeenFetched == false && showFetchAllTransactionsOverlay == false { - Spacer() - - HStack(alignment: .center) { - Spacer() + Section { + HStack { + Spacer() + + Button("Fetch all account transactions") { + self.fetchAllTransactions(self.accountsForWhichNotAllTransactionsHaveBeenFetched) + } - Button("Fetch all account transactions") { - self.fetchAllTransactions(self.accountsForWhichNotAllTransactionsHaveBeenFetched) + Spacer() } - - Spacer() } - .frame(height: 35) + .frame(maxWidth: .infinity, minHeight: 40) + .background(Color(UIColor.systemGroupedBackground)) + .listRowInsets(EdgeInsets()) } } + .background(Color(UIColor.systemGroupedBackground)) if showFetchAllTransactionsOverlay { VStack {