Documentation ¶
Index ¶
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
This section is empty.
Types ¶
type ErrorResponse ¶
type ErrorResponse struct { FailedField string `json:"field"` Tag string `json:"tag"` Value string `json:"value"` }
func ValidateStruct ¶
func ValidateStruct(inputStruct interface{}) []*ErrorResponse
type Pagination ¶
type Pagination struct { TotalCount int64 `json:"total_count"` Limit int `json:"limit"` CurrentPage int `json:"current_page"` TotalPages int `json:"total_pages"` HasNextPage bool `json:"has_next_page"` HasPrevPage bool `json:"has_prev_page"` NextPage int `json:"next_page"` PrevPage int `json:"prev_page"` Data interface{} `json:"data"` }
func Paginate ¶
func Paginate(totalCount, limit, currentPage int, data interface{}) *Pagination
Click to show internal directories.
Click to hide internal directories.