-
Notifications
You must be signed in to change notification settings - Fork 9
#3210 - edit sponsor task endpoint #3309
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
#3210 - edit sponsor task endpoint #3309
Conversation
|
Looks great! I would maybe do postman tests for bad user id and bad sponsor id as well just to be super thorough but I'll ask Jack and Waverly to see what they think! |
dreifusjack
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Great start Sarah! Just left some small reviews, lmk if you have any questions
dreifusjack
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Just some small changes, lmk if you have any questions
dreifusjack
left a comment
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
LGTM. Also when you fix a requested change, can you click resolve conversation? Just to clean up the pr. Thanks!
| if (!(await userHasPermission(submitter.userId, org.organizationId, isHead))) | ||
| throw new AccessDeniedException('Only heads can edit sponsor tasks.'); | ||
|
|
||
| const oldSponsorTask = await prisma.sponsor_Task.findUnique({ |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Search within the organization
|
|
||
| if (!oldSponsorTask) throw new NotFoundException('SponsorTask', sponsorTaskId); | ||
|
|
||
| if (assigneeUserId) { |
There was a problem hiding this comment.
Choose a reason for hiding this comment
The reason will be displayed to describe this comment to others. Learn more.
Same here
Changes
Created the editSponsorTask endpoint.
Test Cases
Screenshots
Checklist
It can be helpful to check the
ChecksandFiles changedtabs.Please review the contributor guide and reach out to your Tech Lead if anything is unclear.
Please request reviewers and ping on slack only after you've gone through this whole checklist.
yarn.lockchanges (unless dependencies have changed)Closes #3210