fix(be): update nonstock query to use SupplierID as a non-pointer type

This commit is contained in:
aguhh18
2025-12-31 09:40:05 +07:00
parent d35d0bbe6b
commit 0fc560b91c
3 changed files with 12 additions and 10 deletions
@@ -23,10 +23,12 @@ func NewNonstockController(nonstockService service.NonstockService) *NonstockCon
}
func (u *NonstockController) GetAll(c *fiber.Ctx) error {
query := &validation.Query{
Page: c.QueryInt("page", 1),
Limit: c.QueryInt("limit", 10),
Search: c.Query("search", ""),
Page: c.QueryInt("page", 1),
Limit: c.QueryInt("limit", 10),
Search: c.Query("search", ""),
SupplierID: uint(c.QueryInt("supplier_id", 0)),
}
if query.Page < 1 || query.Limit < 1 {