Closed hnadrian closed 1 month ago
@xgarcia17 I made a new request for your issue. This code should be the same. There is one more endpoint DELETE to implement.
Code for the additional DELETE endpoint looks great and works! Nice job
@hnadrian I think this is actually more involved. When deleting a Volunteer fully from the database, we have to do the following:
Here's what I propose: we add a field "active" which is a boolean to the Volunteer schema. Instead of our delete endpoint actually deleting data, we just set this boolean to False. This way we don't have to go delete references and entries which may be data we actually want to preserve.
Let me know what you think. We can also leave this PR open and come back when this becomes relevant.
@andrewtchan Thanks for catching this. You're right referencing a nonexistent volunteer is an issue. I agree we should have an active
boolean for the schema! This means we will also make changes to other endpoints for this PR to include active
boolean
Okay, the volunteer schema change with active
boolean is added. Endpoints got some small changes as a result. Tested with Postman. Waiting for review and merge @andrewtchan
Developer: Xavier Garcia
Closes #9
Pull Request Summary
In this branch, I have created and tested endpoints:
Modifications
Created directories:
Testing Considerations
I used the Boomerang extension to test each endpoint manually with the Mongo Dev DB and a localhost server. Additional tests can be done to confirm my results.
Pull Request Checklist