ui: Display count of locked UTXOs on wallet page.

This commit is contained in:
tecnovert
2024-01-28 20:16:30 +02:00
parent 30a5ea1652
commit 9ee6669179
10 changed files with 72 additions and 9 deletions

View File

@@ -300,6 +300,7 @@ class BTCInterface(CoinInterface):
rv = self.rpc_wallet('getwalletinfo')
rv['encrypted'] = 'unlocked_until' in rv
rv['locked'] = rv.get('unlocked_until', 1) <= 0
rv['locked_utxos'] = len(self.rpc_wallet('listlockunspent'))
return rv
def walletRestoreHeight(self) -> int:

View File

@@ -33,9 +33,7 @@ class LTCInterface(BTCInterface):
return self.rpc_wallet('sendtoaddress', params)
def getWalletInfo(self):
rv = self.rpc_wallet('getwalletinfo')
rv['encrypted'] = 'unlocked_until' in rv
rv['locked'] = rv.get('unlocked_until', 1) <= 0
rv = super(LTCInterface, self).getWalletInfo()
mweb_info = self.rpc_wallet_mweb('getwalletinfo')
rv['mweb_balance'] = mweb_info['balance']