vegaprotocol / frontend-monorepo

Toolkit for building apps that interact with Vega
https://vega.xyz
MIT License
25 stars 18 forks source link

Explorer: add unfinalised withdrawals to party deposits & withdrawals box #5569

Closed edd closed 3 months ago

edd commented 10 months ago

Story

As a user with a withdrawal that is not yet finalised I want the Block Explorer accounts page to represent the locked funds So that it doesn't look like I am missing money

Acceptance Criteria

Tasks

Add a call to the withdrawals API, filter for prepared but not yet enacted withdrawals, list them on the page. They should link to the governance withdrawals section to allow a user to complete the withdrawals.

Sketch

Additional details / background info

To identify a withdrawal which is pending on ethereum you want STATUS_FINALIZED and a missing txHash.

eg.

"node": {
"id": "8658118dc769eb04a03a68d5e3060edde760e58cd22022fb9c8b957378cab747",
"partyId": "da9b8ad349b4ad48092aa50d0d0934c8431711ae3fda167ed6e1d4dee0507d12",
"amount": "10061884195072859261",
"asset": "d1984e3d365faa05bcafbe41f50f90e3663ee7c0da22bb1e24b164e9532691b2",
"status": "STATUS_FINALIZED",
"ref": "1703621805",
"txHash": "",
"createdTimestamp": "1703620685521135000",
"withdrawnTimestamp": "0",
"ext": {
"erc20": {
"receiverAddress": "0x73b2AEcF6aDA6F4a579Fa69944dd7fdE2904Db92"
}
}
},
"cursor": "eyJ2ZWdhVGltZSI6IjIwMjMtMTItMjZUMTk6NTg6MDUuNTIxMTM1WiIsImlkIjoiODY1ODExOGRjNzY5ZWIwNGEwM2E2OGQ1ZTMwNjBlZGRlNzYwZTU4Y2QyMjAyMmZiOWM4Yjk1NzM3OGNhYjc0NyJ9"
JonRay15 commented 10 months ago

Note this is covered on console

edd commented 3 months ago

I renamed this, but actually now believe that the Withdrawals/Deposits box on the party page is adequate

Screenshot 2024-07-22 at 16 49 22

It doesn't fix the originally identified issue (i.e. if you look at the accounts page the balance might be lower than expected - see below) but the party page adequately shows the reason

Screenshot 2024-07-22 at 16 49 39