Giveth / giveth-dapps-v2

This project is the aggregation of GIVeconomy and Giveth.io DApps in a single repo
https://staging.giveth.io
GNU General Public License v3.0
62 stars 33 forks source link

Streamline "adding qf matching results to the backend" so it's not a massive manual effort each time #4603

Closed laurenluz closed 4 weeks ago

laurenluz commented 2 months ago

Right now, when a QF round ends, we do data analysis and matching calculations and then end up with a matching fund distribution that we send out via a multisig tx.

Then, a backend dev needs to manually input this data so that it shows up on the dapp.

We should build some way where this can be done fast & more efficiently, and perhaps without a dev (i.e. through AdminJS).

@CarlosQ96 would love your thoughts!

cc @koday1

CarlosQ96 commented 1 month ago

Draft in progress. https://github.com/Giveth/impact-graph/pull/1799 Just missing some small tweaks will leave for review.

CarlosQ96 commented 1 month ago

@maryjaf Can go into the adminjs into the new button in the qfroundhistory tab, bulk update. To test it! It's mostly a tool for me to manually insert things.

Ill add more later but this is a start. Can even divide work with someone with this.

laurenluz commented 1 month ago

on staging @CarlosQ96 ?

@maryjaf leave a comment if you need more context!

CarlosQ96 commented 1 month ago

Yes staging!

maryjaf commented 1 month ago

on staging @CarlosQ96 ?

@maryjaf leave a comment if you need more context!

Thanks @laurenluz I've checked the new button and records in admin js but I haven't understood the issue and how to be checked @CarlosQ96

laurenluz commented 1 month ago

@maryjaf After a QF round ends, we do the data analysis, calculate the matching funds for each project, and then send the funds out to projects.

After doing that, we prepare a csv with:

And input them into the backend so they appear on the project single page donation tab, QF round tab, i.e. here for GIV-Earth example project Diamante luz image

It has been a manual effort so far, Carlos had to import that info into the backend and it's a bit of drag, so we want to make it possible for a QF round manager to upload the data, and have that show up then on the backend.

FYI... before this work is done, the actual matching on the project tab shows as "pending" if the round is complete:

image

The data that we input into the backend is something like this: https://docs.google.com/spreadsheets/d/1xgLx_o8nVqvq95v7OcIFfy8HljrZXBYWsh9vDdsL2jE/edit?gid=0#gid=0

But actually, I think @CarlosQ96 or @koday1 can specify exactly what the format of the inputs here should be.

The goal here is for you to test that an admin can really put in matching fund data (tx hash, token & amount) in adminJS and have it show up seamlessly then in the UI on the dapp.

maryjaf commented 1 month ago

I enter Ids like as the mentioned format in the fields

@CarlosQ96 https://github.com/user-attachments/assets/349f8ec3-8d45-4166-b09a-206811caaece

CarlosQ96 commented 1 month ago

@maryjaf thats an error on the copy of the text but just input the ID, Ill fix the text.

maryjaf commented 1 month ago

When I complete the fields like as below screen record, the data is shown as expected in project donation table only the currency isn't shown in UI for matching fund

https://github.com/user-attachments/assets/425aaa8e-aac0-4d9f-b061-a4523af83fa6

Screenshot 2024-09-30 at 11 41 50 AM

Is there other scenarios to be checked or this is whole thing that we want ? @CarlosQ96 @laurenluz

CarlosQ96 commented 1 month ago

Yes just this for now @maryjaf, so someone can help me input the data jajajajaja

Ill add better options later but adminjs is a lot of work always. This is a start.