helper

package
v0.2.1 Latest Latest
Warning

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

Go to latest
Published: Aug 15, 2017 License: Apache-2.0 Imports: 9 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GetUser

func GetUser(c *gin.Context) (user uic.User, err error)

func JSONR

func JSONR(c *gin.Context, arg ...interface{}) (werror error)

func JSONR(c *gin.Context, wcode int, msg interface{}) (werror error) {

func PageParser

func PageParser(page string, limit string) (p int, l int, err error)

func SessionChecking

func SessionChecking(c *gin.Context) (auth bool, err error)

Types

type RespJson

type RespJson struct {
	Error string `json:"error,omitempty"`
	Msg   string `json:"message,omitempty"`
}

type WebSession

type WebSession struct {
	Name string
	Sig  string
}

func GetSession

func GetSession(c *gin.Context) (session WebSession, err error)

Jump to

Keyboard shortcuts

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