apis

package
v0.0.0-...-50a2d83 Latest Latest
Warning

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

Go to latest
Published: Mar 1, 2023 License: MIT Imports: 4 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Response

type Response struct {
	Code      int         `description: "返回码"`
	Message   string      `description: "返回码描述"`
	Translate string      `description: "返回码提示翻译"`
	Detail    string      `description: "详细错误信息,不展示,仅供调试时使用"`
	Data      interface{} `description: "返回数据"`
}

func (*Response) Error

func (this *Response) Error(err error, detail ...string)

错误返回

func (*Response) Success

func (this *Response) Success(data ...interface{})

成功返回

func (*Response) SuccessNeedReboot

func (this *Response) SuccessNeedReboot(data ...interface{})

成功返回但需要重启设备

Jump to

Keyboard shortcuts

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