fix: add order_by and sort_by query to master data employee

This commit is contained in:
ValdiANS
2026-05-04 16:28:03 +07:00
parent 19d7cd33ca
commit 48351661c5
3 changed files with 19 additions and 7 deletions
@@ -18,4 +18,6 @@ type Query struct {
Search string `query:"search" validate:"omitempty,max=50"`
KandangId *uint `query:"kandang_id" validate:"omitempty"`
IsActive *bool `query:"is_active" validate:"omitempty"`
SortBy string `query:"sort_by" validate:"omitempty,max=50,oneof=name created_at updated_at" default:"updated_at"`
OrderBy string `query:"order_by" validate:"omitempty,oneof=asc desc" default:"desc"`
}