Skip to content
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

Create Unallocated Item Request Mutation #31

Open
7 tasks
kavinphan opened this issue Feb 4, 2025 · 0 comments
Open
7 tasks

Create Unallocated Item Request Mutation #31

kavinphan opened this issue Feb 4, 2025 · 0 comments
Assignees
Labels

Comments

@kavinphan
Copy link
Contributor

Description

Create a POST route handler at /api/unallocatedItems that accepts form data and creates an UnallocatedItemRequest record using the form data. The form data will include the following fields: unallocatedItemId, priority, quantity, and comment.

Success Criteria

  • 401 if no session
  • 403 if user is not a PARTNER
  • 404 if the unallocated item does not exist
  • The form data is validated using a zod schema
  • An UnallocatedItemRequest record is created
  • The route handler is documented with a description of its function, parameters, and responses
  • There is a test file that covers the success criteria
@kavinphan kavinphan assigned alexdcdc and shaply and unassigned alexdcdc Feb 5, 2025
Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
Projects
None yet
Development

No branches or pull requests

3 participants