Documentation
¶
Index ¶
- func EncodeJSON(ctx echo.Context, code int, i interface{}) error
- func ParamDate(ctx echo.Context) types.Date
- func ParamID(ctx echo.Context) uint64
- func ParseDate(v string) types.Date
- func QueryDate(ctx echo.Context, key string) types.Date
- func QueryDateOrNow(ctx echo.Context, key string) types.Date
- func QueryPage(ctx echo.Context) uint64
- func QueryScopes(ctx echo.Context) types.Strings
- type Error
- type OK
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func EncodeJSON ¶
EncodeJSON sends a JSON response with status code.
func QueryDateOrNow ¶
QueryDateOrNow returns the given query as date and if the date is not valid, current date will be used.
Types ¶
type Error ¶
Error is the representation of the error wrapper.
func ErrorWrapper ¶
ErrorWrapper is wrapping code & error message.
type OK ¶
type OK struct {
Code int `json:"code"`
CodeIfEmpty int `json:"-"`
Meta types.Map `json:"meta"`
Data interface{} `json:"data"`
}
OK is the representation of the response wrapper.
Click to show internal directories.
Click to hide internal directories.