api

package
v0.5.1 Latest Latest
Warning

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

Go to latest
Published: Nov 29, 2020 License: GPL-3.0 Imports: 18 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	// User ...
	User = &user{}
	// OAuth2 ...
	OAuth2 = &oauth2{}
	// Role ...
	Role = &role{}
	// Resource ...
	Resource = &resource{}
	// File ...
	File = &file{}
	// Organization ...
	Organization = &organization{}
	// Common ...
	Common = &common{}
	// Casbin ...
	Casbin = &casbin{}
)

Functions

func QueryChildren added in v0.3.0

func QueryChildren(v map[string]gin.HandlerFunc) gin.HandlerFunc

QueryChildren ...

func Writer added in v0.3.0

func Writer(ctx *gin.Context, v interface{})

Writer ...

Types

type Result added in v0.3.0

type Result struct {
	Status string       `json:"status"`
	Data   interface{}  `json:"data,omitempty"`
	Error  *ResultError `json:"error,omitempty"`
}

Result example...

func NewResult added in v0.3.0

func NewResult(v interface{}) (result Result)

NewResult 创建返回结果

type ResultError

type ResultError struct {
	Code    int    `json:"code"`
	Message string `json:"message"`
}

ResultError ...

Jump to

Keyboard shortcuts

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