handler

package
v0.0.0-...-3b47941 Latest Latest
Warning

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

Go to latest
Published: Dec 26, 2021 License: BSD-3-Clause Imports: 8 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var RPCctx = context.Background()

用于 rpc 请求的 ctx

Functions

func CheckAuth

func CheckAuth(c *gin.Context)

func CheckToken

func CheckToken() gin.HandlerFunc

func Count

func Count(c *gin.Context)

func FailResponse

func FailResponse(c *gin.Context, err error)

func GetRoomInfo

func GetRoomInfo(c *gin.Context)

func Login

func Login(c *gin.Context)

func Logout

func Logout(c *gin.Context)

func Push

func Push(c *gin.Context)

func PushRoom

func PushRoom(c *gin.Context)

func Register

func Register(c *gin.Context)

func SuccessResponse

func SuccessResponse(c *gin.Context, data interface{})

Types

type FormRegister

type FormRegister struct {
	UserName string `form:"userName" json:"userName" binding:"required"`
	Password string `form:"passWord" json:"passWord" binding:"required"`
}

type ResponseData

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

Jump to

Keyboard shortcuts

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