Documentation ¶
Index ¶
- func ResponesFILE(c *gin.Context, filename string)
- func ResponseBytes(c *gin.Context, code Code, data ...[]byte)
- func ResponseBytesList(c *gin.Context, code Code, total uint64, data ...[]byte)
- func ResponseDATA(c *gin.Context, data []byte, headers ...map[string]string)
- func ResponseJSON(c *gin.Context, code Code, data ...any)
- func ResponseTEXT(c *gin.Context, code Code, data ...any)
- type Code
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
func ResponesFILE ¶
func ResponseBytesList ¶
Types ¶
type Code ¶
type Code int32
const ( // 业务状态码 CodeServerCallbackTimeout Code = 2000 + iota CodeInvalidLogin CodeInvalidSignup CodeOldPasswordNotMatch CodeNewPasswordNotMatch CodeRequireRoleId CodeNotFoundQueryID CodeNotFoundRouteID CodeNotFoundRoleId CodeNotFoundUser CodeNotFoundUserId CodeNotFoundRoomType CodeNotFoundCategory CodeAlreadyExistsUser CodeAlreadyExistsRole CodeAlreadyExistsRoomType CodeAlreadyExistsCategory CodeTooLargeFile CodeNotPNGJPG CodeInvalidSoftwareLabel )
Click to show internal directories.
Click to hide internal directories.