DA0-DA0 / dao-dao-ui

InterChain DAO tooling UI.
https://daodao.zone
27 stars 21 forks source link

Fix mismatch between chart and table in treasury balances #1732

Open elsehow opened 7 months ago

elsehow commented 7 months ago

image

In the view above, the treasury balance appears mismatched between the chart and the table. The chart indicates the balance is near zero, but the table indicates that the treasury has over 1k USD.

Somewhat related to #1731.

kopeboy commented 5 months ago

Can confirm this. Look the big discrepancy here: image https://daodao.zone/dao/juno1nmezpepv3lx45mndyctz2lzqxa6d9xzd2xumkxf7a6r4nxt0y95qypm6c0/treasury

Basically the difference is attributable to staked coins: the table shows the total (bank balance + staked amount), while the graph shows the available balance only:

junod q bank balances juno1nmezpepv3lx45mndyctz2lzqxa6d9xzd2xumkxf7a6r4nxt0y95qypm6c0
balances:
- amount: "686021124"
  denom: ibc/008BFD000A10BCE5F0D4DD819AE1C1EC2942396062DABDD6AE64A655ABC7085B
- amount: "1712493"
  denom: ibc/C4CFF46FD6DE35CA4CF4CE031E643C8FDC9BA4B99AE598E9B0ED98FE3A2319F9
- amount: "1403"
  denom: ibc/EAC38D55372F38F1AFD68DF7FE9EF762DCF69F26520643CF3F9D292A738D8034
- amount: "1356252651199"
  denom: ujuno
pagination:
  next_key: null
  total: "0"