httpResult

package
v1.0.2 Latest Latest
Warning

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

Go to latest
Published: Aug 23, 2024 License: GPL-2.0 Imports: 2 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func ErrJson

func ErrJson(w http.ResponseWriter, err error)

ErrJson 返回错误

func OkJson

func OkJson(w http.ResponseWriter, data interface{})

OkJson 返回成功

Types

type Resp

type Resp struct {
	Code int         `json:"coe"`
	Msg  string      `json:"msg"`
	Data interface{} `json:"data"`
}

json 返回内容

Jump to

Keyboard shortcuts

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