code4romania / monitorizare-vot

Election monitoring app through which commissioned observers can easily report back to their respective NGOs throughout the election day.
https://votemonitor.org
Mozilla Public License 2.0
36 stars 42 forks source link

Add one more filter on GET ​/api​/v1​/answers #299

Closed aniri closed 3 years ago

aniri commented 3 years ago

It should be able to view the answers by observer phone number.

bjm-csse commented 3 years ago

Hi, I am interested in working on this, thanks! Would you be interested in assigning this to me?

aniri commented 3 years ago

Hi, I am interested in working on this, thanks! Would you be interested in assigning this to me?

@bjm-csse sure, thanks!

aniri commented 3 years ago

hey @bjm-csse any update on this issue? :smile:

bjm-csse commented 3 years ago

@aniri Sorry I was out of town this last week/weekend. I plan to tackle it this week!

bjm-csse commented 3 years ago

@aniri I think I have the changes needed to close this issue but I have been unable to test it. The first barrier being authorizing with the API. The endpoint requires a user, password, and unique id. How do I go about getting these so I can authorize? Also to make sure I'm on the correct path I haven't used Mediatr with the CQRS pattern yet but I'm trying my hardest to understand it, can you check out my changes? Thanks! https://github.com/bjm-csse/monitorizare-vot/tree/feature/filter-phonenum

aniri commented 3 years ago

hey @bjm-csse ! to be able to login you need to add to your local db an ngo and an ngo admin account connected to that ngo. and then only send the user and password set for it from swagger using the access/authorize method to get an auth token to use on the other requests. it is difficult for me to see the code changes like that. could you open a pull request so it would be easier to see the newly added code? thanks!!