add sorting transaction, report keuangan

This commit is contained in:
giovanni
2026-05-16 23:40:52 +07:00
parent a40adc22d2
commit 18bd8ad1d9
8 changed files with 127 additions and 49 deletions
@@ -58,6 +58,7 @@ type DebtSupplierQuery struct {
StartDate string `query:"start_date" validate:"omitempty,datetime=2006-01-02"`
EndDate string `query:"end_date" validate:"omitempty,datetime=2006-01-02"`
FilterBy string `query:"filter_by" validate:"omitempty,oneof=received_date po_date"`
SortBy string `query:"sort_by" validate:"omitempty,oneof=supplier"`
SortOrder string `query:"sort_order" validate:"omitempty,oneof=asc desc"`
AllowedAreaIDs []int64 `query:"-"`
AllowedLocationIDs []int64 `query:"-"`
@@ -108,6 +109,8 @@ type CustomerPaymentQuery struct {
Limit int `query:"limit" validate:"omitempty,min=1,gt=0"`
CustomerIDs []uint `query:"customer_ids" validate:"omitempty,dive,gt=0"`
FilterBy string `query:"filter_by" validate:"omitempty,oneof=TRANS_DATE REALIZATION_DATE"`
SortBy string `query:"sort_by" validate:"omitempty,oneof=customer"`
SortOrder string `query:"sort_order" validate:"omitempty,oneof=asc desc"`
StartDate string `query:"start_date" validate:"omitempty,datetime=2006-01-02"`
EndDate string `query:"end_date" validate:"omitempty,datetime=2006-01-02"`
}