unicef / juniper-portfolio

This application can be used to track cryptocurrency wallets (bitcoin and ether).

Geek Repo:Geek Repo

Github PK Tool:Github PK Tool

Accounts Page: Requirements Update

mehranhydary opened this issue Β· comments

Accounts Page Updates

Note: please ensure that all balances follow the same convention across the app (USD has $ and 2 decimal points and ETH balances should have 4 decimal points)

On the accounts page we are currently tracking donors, payees and natcoms. Updates are required for this page to show information different than we have it now.

Payees

  1. Ensure that the value shown here is a summation of how much ETH and BTC we've given to our startups; should be 1225 ether and 1 bitcoin.

Screen Shot 2021-01-06 at 12 23 40 PM

  1. Each of the payee accounts have cards. The cards should show how much they have received from UNICEF HQ (e.g. Atix Labs has received 62.5 ETH and 1 BTC from UNICEF HQ and Utopixar has received 49.5 ETH from UNICEF HQ). Right now the cards show the current balance of the wallets - please update so that it reflects how much UNICEF HQ has sent them.

Screen Shot 2021-01-06 at 12 27 22 PM

Donors

  1. Ensure that the value here shows how much ETH and BTC we have received from donors. The values should be 2267 ETH and 1 BTC. This should match the amount of crypto flowing through Natcom wallets.

Screen Shot 2021-01-06 at 12 44 28 PM

  1. Ensure that the cards for each of the donors show the amount that they have sent to UNICEF HQ (e.g. Animoca Brands should show 167 ETH sent and Ethereum Foundation should show 2100 ETH and 1 BTC).

Screen Shot 2021-01-06 at 12 55 22 PM

  1. In the detailed wallets card for the Donor, please show transactions that have been tagged with a donor here (e.g. EF -> UNICEF France -> UNICEF HQ).

Screen Shot 2021-01-06 at 12 58 29 PM

  1. In the detailed wallets card for the donor, please update the values in the top section to show the amount they donated.

Screen Shot 2021-01-06 at 12 58 18 PM

Natcoms

  1. Please show what crypto they have sent to UNICEF HQ (should be 2267 ETH and 1 BTC). I think right now we are just pulling the balance.

Screen Shot 2021-01-06 at 1 04 22 PM

  1. For each of the natcom cards, please show how much eth / btc they have sent to the HQ wallets

Screen Shot 2021-01-06 at 1 05 09 PM

@CriLoma @tenthirtyone - Can you check this out and lmk if this is what we discussed for the Accounts page.

For Payees, point #2....

here are the tallies of what companies have received:
Atix = 62.5 ETH + 1 BTC
Utopixar is 49.5 ETH
Prescrypto is 49.5 ETH
OS City is = 125 + 62.5 ETH

the rest are 125 ETH
Somleng
Avyantra
StaTwig
Utopic Studio
Ideasis
Afinidata
Cireha

Here are the requirements I could pull out with questions.

Req 1: All USD prices are formatted with a leading $ (no space) and 2 decimal places (Just for tx page or across the entire app?)

Req 2: All Eth balances have 4 decimal places (How many for Bitcoin? Across entire app or just accounts?)

Req 3: For each Account tab, Payees, Donors, Natcoms, restrict the transactions to those coming from/going to UNICEF wallets defined in Juniper.

Payee totals use transactions from UNICEF Wallets to Payees.

Natcom totals use transactions to UNICEF wallets from Natcom addresses.

After a donor is tagged on a transaction the summary amounts use the tagged address donation amounts. Please see (https://docs.google.com/document/d/1gfkufAVx-MgVGwWN438smBp7Dx2xrfnuFeKr_U-VebU/edit?usp=sharing) for the number of combinations that need accounted for.

Req 4: Each Card per account is the break out amounts used for the summary totals in Req 3.

Req 5: It is not technically feasible to show how much has moved from a Donor -> Natcom -> HQ Wallet. We've only ever tracked Donor -> Natcom. It is also technically impossible to track Donor -> Natcom -> HQ Wallet because Ethereum wallets settle their state every block. You cannot say "This 10 Eth came from here, this 3.5 from here, etc"

Req 6: For the donor account details, use txs where they are tagged. What do Startup/Natcom show for the details?

This also makes the 'amount' field when defining addresses moot/pointless what design update/change should be made since the manual data entry totals will not be used in favor of the transactions amounts on hand. Also, until we have swapped out all of the free api access or changed the wallet polling to a listener that updates txs as they occur this could be brittle with respect to having the amounts/data correct if the free API access is used up/limited or otherwise fails.

Also wasn't there a unique requirements for the donors pages. Where Natcoms/Payees show a count of the natcom/payee entities in the page title near the summary I thought the donors page was changed to a count of the donor transactions (e.g. 8 donations) instead of a count of the unique donor entities

Also wasn't there a unique requirements for the donors pages. Where Natcoms/Payees show a count of the natcom/payee entities in the page title near the summary I thought the donors page was changed to a count of the donor transactions (e.g. 8 donations) instead of a count of the unique donor entities

Leave the titles as is; Payees will show count (n Investments), Donors will show count (n Donors) and Natcoms will have the string that is there (Total donations from National Committees).

This also makes the 'amount' field when defining addresses moot/pointless what design update/change should be made since the manual data entry totals will not be used in favor of the transactions amounts on hand. Also, until we have swapped out all of the free api access or changed the wallet polling to a listener that updates txs as they occur this could be brittle with respect to having the amounts/data correct if the free API access is used up/limited or otherwise fails.

  1. Yes I don't think we need the 'amount' field in the accounts section anymore. We should be able to use th transactions that we have to pull. the values required for each card. Can you let me know what are the design update is required? Maybe you can share a photo or we can hop on a call on Friday.
  2. Does it makes sense to log the API thing as an issue for now?

Here are the requirements I could pull out with questions.

Req 1: All USD prices are formatted with a leading $ (no space) and 2 decimal places (Just for tx page or across the entire app?)

Req 2: All Eth balances have 4 decimal places (How many for Bitcoin? Across entire app or just accounts?)

Req 3: For each Account tab, Payees, Donors, Natcoms, restrict the transactions to those coming from/going to UNICEF wallets defined in Juniper.

Payee totals use transactions from UNICEF Wallets to Payees.

Natcom totals use transactions to UNICEF wallets from Natcom addresses.

After a donor is tagged on a transaction the summary amounts use the tagged address donation amounts. Please see (https://docs.google.com/document/d/1gfkufAVx-MgVGwWN438smBp7Dx2xrfnuFeKr_U-VebU/edit?usp=sharing) for the number of combinations that need accounted for.

Req 4: Each Card per account is the break out amounts used for the summary totals in Req 3.

Req 5: It is not technically feasible to show how much has moved from a Donor -> Natcom -> HQ Wallet. We've only ever tracked Donor -> Natcom. It is also technically impossible to track Donor -> Natcom -> HQ Wallet because Ethereum wallets settle their state every block. You cannot say "This 10 Eth came from here, this 3.5 from here, etc"

Req 6: For the donor account details, use txs where they are tagged. What do Startup/Natcom show for the details?

Req 1: Yes to entire app; if this is too much work we can defer for now
Req 2: Yes to entire app; bitcoin and ether should both have 4 decimal places; if this is too much work we can defer for now
Req 3: Yes
Req 4: Yes
Req 5: If a Natcom -> HQ tx has been tagged to a donor - is there a way to use that tag to do the summation for the donor cards? Let's hop on a call tomorrow to discuss in detail.
Req 6: Startup + Natcom should also have transactions; I think the way the cards are now are fine.

Req 1 & 2: Yup, all the number formatting goes through: https://github.com/unicef/juniper-portfolio/blob/develop/client/src/util/index.js#L17

usd/cryptoformatter functions to standardize across the app.

Req 5: Yup, I think this is the way. The donor account details will be the only section relying on the manual data entry from the transaction tagging.

One unknown/unknown I think coming from #5 is the user can spell the donor name wrong. Not a bug but an unaccounted for user flow. So two records for the same donor would exist but with different spellings. The tagged tx could just switch the donor to the correct donor. The accounts page donor tab would still show both donors. I think this is possible with all of the forms, I will log a separate issue to track.