SSF-225 FM Deleting & Editing Donation Item Backend#188
Conversation
There was a problem hiding this comment.
changes requested for codebase consistency!
let's have oz/value for donation items stay optional in the backend while the frontend requires them to match the create donation items & confirm item details contracts.
edit: i just saw your new pr up which updates those backend fields to be required & since it is better to match be + fe contracts and it's already implemented...let's keep it required in the be then, thanks for taking care of that :)
dburkhart07
left a comment
There was a problem hiding this comment.
very very clean pr! few small things and one question worth discussing, but aside from that lgtm!
| @Min(1) | ||
| quantity!: number; | ||
|
|
||
| @IsNumber( |
There was a problem hiding this comment.
@Yurika-Kan can you explain the rationale behind making these required? the case im considering:
if i make a new donation with 2 items where i dont fill out the ozPerItem and estimatedValue, the next time i go to update the donation, i cant just make an edit to one of them, i have to update all fields for all values. i think they should be allowed to go in and just update the ozPerItem for one item if thats all they have.
lmk if im missing something though!
There was a problem hiding this comment.
To my understanding we cannot now make new donation items without ozPerItem and estimatedValue?
There was a problem hiding this comment.
They wanted to make all those fields now required upon creation so this was to keep consistency with that request
There was a problem hiding this comment.
ie oz, donation val, food rescue
ℹ️ Issue
Closes https://vidushimisra.atlassian.net/browse/SSF-225
📝 Description
Added backend support for patch route donations/:donationId/item to allow adding, editing and deleting donation items for a donation.
✔️ Verification
Postman verified and service/controller tests
🏕️ (Optional) Future Work / Notes
N/A