Back to godoc.org

Package responseutil

v0.0.0-...-139547c
Latest Go to latest

The highest tagged major version is .

Published: Jan 18, 2020 | License: Apache-2.0 | Module: github.com/MarvinShawn/Orange

Index

func GinSendResponse

func GinSendResponse(c *gin.Context, err error, data interface{})

统一发送Response方法

type Gin

type Gin struct {
	Ctx *gin.Context
}

type Response

type Response struct {
	Code    int         `json:"code"`
	Message string      `json:"msg"`
	Data    interface{} `json:"data"`
}

Package Files

Documentation was rendered with GOOS=linux and GOARCH=amd64.

Jump to identifier

Keyboard shortcuts

? : This menu
/ : Search site
f or F : Jump to identifier