mirror of
https://github.com/status-im/status-desktop.git
synced 2025-01-11 06:47:01 +00:00
parent
964aa7ebc9
commit
9af1734c6a
@ -62,7 +62,7 @@ proc init*(self: Controller) =
|
||||
self.events.on(SIGNAL_HISTORY_ERROR) do (e:Args):
|
||||
let accounts = self.getWalletAccounts()
|
||||
let addresses = accounts.map(account => account.address)
|
||||
self.delegate.setHistoryFetchState(addresses, isFetching = false)
|
||||
self.delegate.setHistoryFetchState(addresses, isFetching = false, hasMore = false)
|
||||
|
||||
self.events.on(SIGNAL_TRANSACTIONS_LOADED) do(e:Args):
|
||||
let args = TransactionsLoadedArgs(e)
|
||||
|
@ -35,6 +35,9 @@ method setTrxHistoryResult*(self: AccessInterface, transactions: seq[Transaction
|
||||
method setHistoryFetchState*(self: AccessInterface, addresses: seq[string], isFetching: bool) {.base.} =
|
||||
raise newException(ValueError, "No implementation available")
|
||||
|
||||
method setHistoryFetchState*(self: AccessInterface, addresses: seq[string], isFetching: bool, hasMore: bool) {.base.} =
|
||||
raise newException(ValueError, "No implementation available")
|
||||
|
||||
method setHistoryFetchState*(self: AccessInterface, address: string, allTxLoaded: bool, isFetching: bool) {.base.} =
|
||||
raise newException(ValueError, "No implementation available")
|
||||
|
||||
|
@ -140,9 +140,13 @@ method setTrxHistoryResult*(self: Module, transactions: seq[TransactionDto], col
|
||||
method setHistoryFetchState*(self: Module, addresses: seq[string], isFetching: bool) =
|
||||
self.view.setHistoryFetchStateForAccounts(addresses, isFetching)
|
||||
|
||||
method setHistoryFetchState*(self: Module, addresses: seq[string], isFetching: bool, hasMore: bool) =
|
||||
self.view.setHistoryFetchStateForAccounts(addresses, isFetching, hasMore)
|
||||
|
||||
method setHistoryFetchState*(self: Module, address: string, allTxLoaded: bool, isFetching: bool) =
|
||||
self.view.setHistoryFetchState(address, allTxLoaded, isFetching)
|
||||
|
||||
|
||||
method setIsNonArchivalNode*(self: Module, isNonArchivalNode: bool) =
|
||||
self.view.setIsNonArchivalNode(isNonArchivalNode)
|
||||
|
||||
|
@ -87,6 +87,10 @@ QtObject:
|
||||
else:
|
||||
self.setHistoryFetchState(address, allTxLoaded = false, isFetching)
|
||||
|
||||
proc setHistoryFetchStateForAccounts*(self: View, addresses: seq[string], isFetching: bool, hasMore: bool) =
|
||||
for address in addresses:
|
||||
self.setHistoryFetchState(address, allTxLoaded = not hasMore, isFetching)
|
||||
|
||||
proc setModel*(self: View, address: string) {.slot.} =
|
||||
if not self.models.hasKey(address):
|
||||
self.models[address] = newModel()
|
||||
|
Loading…
x
Reference in New Issue
Block a user