[WorkOrders] Implementation (Router) #171
Labels
No labels
CI/CD
MongoDB
PostgreSQL
api
authentication
bug
documentation
duplicate
enhancement
example issue
fix
good first issue
help wanted
high-level requirement
infrastructure
invalid
low-level requirement
medium-level requirement
question
security
test
wontfix
No milestone
No project
No assignees
1 participant
Notifications
Due date
No due date set.
Dependencies
No dependencies set.
Reference
AndreFerreira5/starranja#171
Loading…
Add table
Add a link
Reference in a new issue
No description provided.
Delete branch "%!s()"
Deleting a branch is permanent. Although the deleted branch may continue to exist for a short time before it actually gets removed, it CANNOT be undone in most cases. Continue?
Create src/routers/work_orders.py.
POST /: Create a new WO. Retrieve current user UUID for created_by_id. Handle 409 Conflict.
GET /{id}: Retrieve single WO.
GET /: List WOs with query params:
?work_order_number={str} -> Calls repo.get_by_work_order_number.
?vehicle_id={id}&active_only=true -> Calls repo.get_active_by_vehicle_id.
?vehicle_id={id} -> Calls repo.get_by_vehicle_id.
?client_id={id} -> Calls repo.get_by_client_id.
PATCH /{id}: Update WO using WorkOrderUpdate schema.
DELETE /{id}: Delete a WO.