Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type Alert ¶
type Alert struct { Pagination Code string `bind:"code_train"` StationID int `bind:"station_id"` }
Alert filter
type Filter ¶
type Filter interface { ApplyFilter(db *gorm.DB) *gorm.DB ApplyPagination(db *gorm.DB) *gorm.DB GetPage() int GetLimit() int }
Filter interface
type Pagination ¶
Pagination query param
func (*Pagination) ApplyFilter ¶
func (p *Pagination) ApplyFilter(db *gorm.DB) *gorm.DB
ApplyFilter on query
func (*Pagination) ApplyPagination ¶
func (p *Pagination) ApplyPagination(db *gorm.DB) *gorm.DB
ApplyPagination on query
func (*Pagination) GetLimit ¶
func (p *Pagination) GetLimit() int
GetLimit return safe limit_per_page (no negative or too large)
func (*Pagination) GetPage ¶
func (p *Pagination) GetPage() int
GetPage return safe page (no negative)
Click to show internal directories.
Click to hide internal directories.