feat: inventory tracking API #82
Reference in New Issue
Block a user
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?
Ref:
docs/ROADMAP.md§ Appendix B / 1.6 Location & Inventory APIsDatabase table exists (
inventorytable inmigrations/001_initial.sql) but no repository layer, routes, or handlers are implemented. Depends on #81 (location CRUD).Database schema (already exists):
Tasks:
internal/db/inventory.go— repository with query, adjust, and move methodsinternal/api/inventory_handlers.go— HTTP handlersinternal/api/routes.go:GET /api/inventory/{partNumber}— get inventory across all locationsPOST /api/inventory/{partNumber}/adjust— adjust quantity at a locationPOST /api/inventory/{partNumber}/move— move quantity between locationsRelated: #56 (broader inventory-location model issue), #81 (location CRUD — prerequisite)