From 5cc6ad194fbd08455f79f552fb6f81f43fde9578 Mon Sep 17 00:00:00 2001 From: Anthony Laibe Date: Tue, 31 Jan 2023 11:35:41 +0100 Subject: [PATCH] fix(@wallet): no tx found fixes #9320 --- .../modules/main/wallet_section/transactions/controller.nim | 3 ++- ui/imports/shared/views/HistoryView.qml | 2 +- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/src/app/modules/main/wallet_section/transactions/controller.nim b/src/app/modules/main/wallet_section/transactions/controller.nim index 718816278b..88a683f43d 100644 --- a/src/app/modules/main/wallet_section/transactions/controller.nim +++ b/src/app/modules/main/wallet_section/transactions/controller.nim @@ -50,7 +50,7 @@ proc init*(self: Controller) = self.events.on(SIGNAL_HISTORY_READY) do (e:Args): let args = HistoryArgs(e) - self.delegate.setHistoryFetchState(args.addresses, isFetching = false) + self.delegate.setHistoryFetchState(args.addresses, isFetching = true) self.events.on(SIGNAL_HISTORY_NON_ARCHIVAL_NODE) do (e:Args): let accounts = self.getWalletAccounts() @@ -65,6 +65,7 @@ proc init*(self: Controller) = self.events.on(SIGNAL_TRANSACTIONS_LOADED) do(e:Args): let args = TransactionsLoadedArgs(e) + self.delegate.setHistoryFetchState(@[args.address], isFetching = false) self.delegate.setTrxHistoryResult(args.transactions, args.address, args.wasFetchMore) self.events.on(SIGNAL_TRANSACTION_SENT) do(e:Args): diff --git a/ui/imports/shared/views/HistoryView.qml b/ui/imports/shared/views/HistoryView.qml index 36ce7aa92b..d3d51f75d6 100644 --- a/ui/imports/shared/views/HistoryView.qml +++ b/ui/imports/shared/views/HistoryView.qml @@ -60,7 +60,7 @@ ColumnLayout { StyledText { id: noTxs - visible: transactionListRoot.count === 0 + visible: !isLoading && transactionListRoot.count === 0 text: qsTr("No transactions found") font.pixelSize: Style.current.primaryTextFontSize }