Display totals as free + reserved

This commit is contained in:
Jaco Greeff 2020-07-23 15:31:11 +02:00
parent d648b756f4
commit efef8e8834
2 changed files with 3 additions and 3 deletions

View File

@ -103,7 +103,7 @@ function Account ({ account: { address, meta }, className = '', delegation, filt
useEffect((): void => {
if (balancesAll) {
setBalance(address, balancesAll.freeBalance);
setBalance(address, balancesAll.freeBalance.add(balancesAll.reservedBalance));
api.api.tx.vesting?.vest && setVestingTx(() =>
balancesAll.vestingLocked.isZero()
? null

View File

@ -241,7 +241,7 @@ function renderBalances (props: Props, allAccounts: string[], t: <T = string> (k
<Label label={t<string>('total')} />
<FormatBalance
className='result'
value={balancesAll.votingBalance}
value={balancesAll.freeBalance.add(balancesAll.reservedBalance)}
/>
</>
)}
@ -361,7 +361,7 @@ function renderBalances (props: Props, allAccounts: string[], t: <T = string> (k
if (withBalanceToggle) {
return (
<>
<Expander summary={<FormatBalance value={balancesAll?.votingBalance} />}>
<Expander summary={<FormatBalance value={balancesAll && balancesAll.freeBalance.add(balancesAll.reservedBalance)} />}>
<div className='body column'>
{allItems}
</div>