ProjectSidewalk / SidewalkWebpage

Project Sidewalk web page
http://projectsidewalk.org
MIT License
80 stars 23 forks source link

Including Anon Users With Validations in Admin Dashboard #3539

Closed srihariKrishnaswamy closed 2 months ago

srihariKrishnaswamy commented 2 months ago

Resolves #3419

In this PR, I edited the UserDAOSlick file in the backend to send anonymous users that have validated data to the admin dashboard frontend, which it did not do previously (only anon users that had done labels and non-anonymous users were sent). This took adding one subquery to the usersMinusAnonUsersWithNoLabels method to include those new anonymous users.

Testing instructions
  1. Make a new user
  2. Go into the database and change their role to id = 6 (anon)
  3. log into an admin user and go to the admin dashboard. Here you can check that that new user you just made does NOT come up.
  4. log back into the new user you made & do one validation mission
  5. log back into the admin user again and go to the admin dashboard. This time, the new user we just made should be visible in the dashboard!
Things to check before submitting the PR