Files
2026-11-23 12:58:04 +03:00

24 lines
600 B
Go
Raw Permalink Blame History

This file contains ambiguous Unicode characters
This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.
package domain
import "time"
const (
DefaultOrderField = "created_at"
DefaultOrderType = "desc"
)
type LimitOffsetParams struct {
Limit uint64 `validate:"required"` // Максимальное количество записей
Offset uint64 // Отступ для выборки
}
type OrderParams struct {
Field string // Поле сортировки
Type string `validate:"oneof=asc desc ASC DESC"` // Порядок сортировки
}
type DateFromToParams struct {
From time.Time `validate:"required"` // Дата с
To time.Time `validate:"required"` // Дата до
}