extension

package
v0.0.0-...-4bcbab6 Latest Latest
Warning

This package is not in the latest version of its module.

Go to latest
Published: Feb 12, 2021 License: MIT Imports: 12 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func BindAndValidate

func BindAndValidate(c echo.Context, i interface{}, rules ...vd.Rule) error

func ErrorHandler

func ErrorHandler(logger *zap.Logger) echo.HTTPErrorHandler

func GetRequestID

func GetRequestID(c echo.Context) string

func Wrap

func Wrap(repo repository.Repository, config config.Config) echo.MiddlewareFunc

Types

type Context

type Context struct {
	echo.Context
}

func (*Context) JSON

func (c *Context) JSON(code int, i interface{}) (err error)

type ErrorMessage

type ErrorMessage struct {
	Code    int
	Message string
}

type Response

type Response struct {
	Message string      `json:"message"`
	Data    interface{} `json:"data"`
}

Directories

Path Synopsis

Jump to

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to
y or Y : Canonical URL