Skip to content
New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

conditional checks on diff parameters in adminJS for deverification #1848

Open
divine-comedian opened this issue Oct 1, 2024 · 10 comments
Open
Assignees
Labels
DeVerification Decentralizing Project Verification

Comments

@divine-comedian
Copy link
Collaborator

divine-comedian commented Oct 1, 2024

need to do some conditional checking and error handling in adminJS

make sure in the admin that when you change a status that is dependent on the other

I made a table here that hopefully can carefully explain the impact of each action in the admin and what the expected outcome should be on the projects status for a variety of conditions

there are 4 columns:

  1. the current status of the 3 relevant values: givbacks form, verified, isGIVbacksEligible
  2. the action being applied
  3. the expected status of the 3 values
  4. notes (error conditions etc..)

you can also view the sheet in google where it might look a bit easier to follow
https://docs.google.com/spreadsheets/d/1RTvg0YaMjEyZOgUpW1i0YQPnnlEPgHZM7ZDXq5e39ro/edit?usp=sharing

current status action expected status notes
givbacks form verified isGIVbacksEligible givbacks form verified isGIVbacksEligible
not started FALSE FALSE approve vouched not started TRUE FALSE send projectVouched email
incomplete FALSE FALSE approve vouched incomplete TRUE FALSE send projectVouched email
submitted FALSE FALSE approve vouched submitted TRUE FALSE send projectVouched email
approved TRUE TRUE approve vouched approved TRUE TRUE (no status change)
declined FALSE FALSE approve vouched declined TRUE FALSE send projectVouched email
not started TRUE FALSE remove vouched not started FALSE FALSE send projectUnvouched email
incomplete TRUE FALSE remove vouched incomplete FALSE FALSE send projectUnvouched email
submitted TRUE FALSE remove vouched submitted FALSE FALSE send projectUnvouched email
approved TRUE TRUE remove vouched throws error -- -- (cannot revoke Vouched badge of GIVbacks eligible project)
declined TRUE FALSE remove vouched declined FALSE FALSE send projectUnvouched email
not started TRUE FALSE approve projects (project verification form) throws error TRUE -- (cannot approve unsubmitted or incomplete application)
not started FALSE FALSE approve projects (project verification form) throws error FALSE -- (cannot approve unsubmitted or incomplete application)
incomplete TRUE FALSE approve projects (project verification form) throws error TRUE -- (cannot approve unsubmitted or incomplete application)
incomplete FALSE FALSE approve projects (project verification form) throws error FALSE -- (cannot approve unsubmitted or incomplete application)
submitted TRUE FALSE approve projects (project verification form) approved TRUE TRUE
submitted FALSE FALSE approve projects (project verification form) approved TRUE TRUE
approved TRUE TRUE approve projects (project verification form) approved TRUE TRUE (no status change)
approved FALSE TRUE approve projects (project verification form) approved TRUE TRUE (should be impossible for verified = false while GIVbacks eligible = true
declined TRUE FALSE approve projects (project verification form) approved TRUE TRUE
declined FALSE FALSE approve projects (project verification form) approved TRUE TRUE
not started TRUE FALSE reject projects (project verification form) throws error TRUE -- (cannot reject unsubmitted or incomplete application)
not started FALSE FALSE reject projects (project verification form) throws error FALSE -- (cannot reject unsubmitted or incomplete application)
incomplete TRUE FALSE reject projects (project verification form) throws error TRUE -- (cannot reject unsubmitted or incomplete application)
incomplete FALSE FALSE reject projects (project verification form) throws error FALSE -- (cannot reject unsubmitted or incomplete application)
submitted TRUE FALSE reject projects (project verification form) declined TRUE FALSE
submitted FALSE FALSE reject projects (project verification form) declined FALSE FALSE
approved TRUE TRUE reject projects (project verification form) declined TRUE FALSE
approved FALSE TRUE reject projects (project verification form) declined FALSE FALSE
declined TRUE FALSE reject projects (project verification form) declined TRUE FALSE (no status change)
declined FALSE FALSE reject projects (project verification form) declined FALSE FALSE (no status change)
not started TRUE FALSE revoke givbacks eligible (project verification form) not started TRUE FALSE
incomplete TRUE FALSE revoke givbacks eligible (project verification form) incomplete TRUE FALSE
submitted TRUE FALSE revoke givbacks eligible (project verification form) submitted TRUE FALSE
approved TRUE TRUE revoke givbacks eligible (project verification form) throws error TRUE FALSE
declined TRUE FALSE revoke givbacks eligible (project verification form) declined TRUE FALSE (no status change)

@divine-comedian divine-comedian converted this from a draft issue Oct 1, 2024
@divine-comedian divine-comedian moved this from New Issues to Dev Research in Decentralized Verification Oct 1, 2024
@divine-comedian divine-comedian changed the title boolean swaps on diff parameters in adminJS for deverification conditional checks on diff parameters in adminJS for deverification Oct 1, 2024
@divine-comedian divine-comedian added the DeVerification Decentralizing Project Verification label Oct 1, 2024
@github-project-automation github-project-automation bot moved this to New Issues in All-Devs Oct 3, 2024
@divine-comedian divine-comedian moved this from New Issues to Dev Research in All-Devs Oct 3, 2024
@divine-comedian
Copy link
Collaborator Author

@MohammadPCh what is the update on this? Is it being worked on through #1866 ?

@divine-comedian divine-comedian moved this from Dev Research to QA in All-Devs Dec 23, 2024
@divine-comedian
Copy link
Collaborator Author

@LatifatAbdullahi

I made a table here that hopefully can carefully explain the impact of each action in the admin and what the expected outcome should be on the projects status for a variety of conditions

there are 4 columns:

  1. the current status of the 3 relevant values: givbacks form, verified, isGIVbacksEligible
  2. the action being applied
  3. the expected status of the 3 values
  4. notes (error conditions etc..)

you can also view the sheet in google where it might look a bit easier to follow
https://docs.google.com/spreadsheets/d/1RTvg0YaMjEyZOgUpW1i0YQPnnlEPgHZM7ZDXq5e39ro/edit?usp=sharing

What to test

run through each scenario by using the admin panel on staging https://impact-graph.serve.giveth.io/admin/login

  1. ensure project conditions match defined in current status for each row
  2. perform action
  3. ensure project status after performed action matches what is expected according to last 3 columns for each row

where to test

https://impact-graph.serve.giveth.io/admin/login with VPN access credentials enabled

"givbacks form"

Image

"verified, vouched & givbacks eligible"

Image

@LatifatAbdullahi
Copy link

@CarlosQ96

I am not able to Filter for Newly created projects by Title as well as date created.

Please kindly take a look

image

@CarlosQ96
Copy link
Collaborator

@divine-comedian @LatifatAbdullahi should be able to resume testing. Kecchy told me staging was conected to prod. That was now reverted.

The projects didnt appear because the admin was staging's, while the project creation was ocurring in prod.

@LatifatAbdullahi
Copy link

Test Update

@MohammadPCh @mateodaza @divine-comedian

Test performed and completed for all scenarios in this sheet https://docs.google.com/spreadsheets/d/1RTvg0YaMjEyZOgUpW1i0YQPnnlEPgHZM7ZDXq5e39ro/edit?usp=sharing

All scenarios passed except for the following issues listed below

Issues

    • Wrong response message: "Cannot read properties of undefined (reading 'walletAddress')"

    • Vouched Email sent : Failed

Action - Approve vouch / Remove vouch
Action response - successful
GivBack Form - Not submitted

image

    • Vouched Email sent : Failed

Action - Approve vouch
GivBack Form - Incomplete
Vouched - True

    • Vouched Email sent : Failed

Action - Approve vouch
GivBack Form - Submitted
Vouched - True

    • Vouched Email sent : Failed

Action - Approve vouch
GivBack Form - Declined
Vouched - True

    • UnVouched Email sent : Failed

Action - Remove vouch
Vouched - True
Givback Form - not started
Givback Form - incomplete
Givback Form - submitted
Givback Form - declined
Givback Form - not started

@divine-comedian
Copy link
Collaborator Author

divine-comedian commented Jan 6, 2025

Thanks for that @LatifatAbdullahi - We haven't done that issue yet to design and attach the email sending to these flows, I should have clarified that earlier in this issue. I'm still waiting to see how successful the feature is before we develop more features such as sending notification emails.

Giveth/notification-center#114

If the only issues you recognize are failed to send emails then I think we can follow that up in this other issue as part of the testing requirements.

@LatifatAbdullahi
Copy link

Thanks @divine-comedian for the clarification, then issue below will be left to be fixed.

@MohammadPCh @mateodaza

Issue

  1. Wrong success/error response when Users Approve vouch/remove vouch

Response message: "Cannot read properties of undefined (reading 'walletAddress')"

image

@divine-comedian
Copy link
Collaborator Author

@LatifatAbdullahi do you mind sharing a screen recording of how you approved or removed vouch status? Which buttons did you press inside the admin panel?

@LatifatAbdullahi
Copy link

LatifatAbdullahi commented Jan 6, 2025

Sure, Here!

Steps

  1. Login to to the AdminJS
  2. Click on "Project"
  3. Search/Filter for preferred Project
  4. To Approve vouch, select Project
  5. Click from the displayed options above "Approve Vouched"
  6. To Remove vouch. select Project
  7. Click from the displayed options above "Remove vouched"
Giveth.-.Google.Chrome.2025-01-06.22-08-57.mp4
Giveth.-.Google.Chrome.2025-01-06.22-29-15.mp4

@divine-comedian

Below attached is a recording for the Scenario we discussed

Scenario:

Form status : submitted

Verified status: False
Givback Eligiblity status: False

Action: Approved submitted Form

Result: Verified status - True

Givback status - True

Giveth.-.Google.Chrome.2025-01-07.09-03-27.mp4

@MoeNick MoeNick moved this from QA to In Progress in All-Devs Jan 13, 2025
@MoeNick
Copy link
Member

MoeNick commented Jan 13, 2025

@CarlosQ96 can double check it.

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
DeVerification Decentralizing Project Verification
Projects
Status: In Progress
Status: Dev Research
Development

No branches or pull requests

6 participants