qrcode

package
v1.0.1 Latest Latest
Warning

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

Go to latest
Published: Jul 13, 2024 License: Apache-2.0 Imports: 16 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

This section is empty.

Types

type Forward

type Forward string

Forward Forward

const (
	// ForwardNative 原生跳转
	ForwardNative Forward = "native"
	// ForwardH5 h5跳转
	ForwardH5 Forward = "h5"
)

func (Forward) MarshalJSON

func (q Forward) MarshalJSON() ([]byte, error)

MarshalJSON MarshalJSON

func (*Forward) UnmarshalJSON

func (q *Forward) UnmarshalJSON(b []byte) error

UnmarshalJSON UnmarshalJSON

type HandleResult

type HandleResult struct {
	Forward Forward                `json:"forward"` // 跳转方式
	Type    HandlerType            `json:"type"`    // 数据类型
	Data    map[string]interface{} `json:"data"`    // 数据
}

HandleResult 二维码处理结果

func NewHandleResult

func NewHandleResult(forward Forward, typ HandlerType, data map[string]interface{}) *HandleResult

NewHandleResult NewHandleResult

type HandlerType

type HandlerType string

HandlerType HandlerType

const (
	// HandlerTypeWebView HandlerTypeWebView
	HandlerTypeWebView HandlerType = "webview"
	// HandlerTypeGroup 群组
	HandlerTypeGroup HandlerType = "group"
	// HandlerTypeLoginConfirm 扫描登录确认
	HandlerTypeLoginConfirm HandlerType = "loginConfirm"
	// HandlerTypeUserInfo 跳转到用户资料页面
	HandlerTypeUserInfo HandlerType = "userInfo"
)

func (HandlerType) MarshalJSON

func (q HandlerType) MarshalJSON() ([]byte, error)

MarshalJSON MarshalJSON

func (*HandlerType) UnmarshalJSON

func (q *HandlerType) UnmarshalJSON(b []byte) error

UnmarshalJSON UnmarshalJSON

type QRCode

type QRCode struct {
	log.Log
	// contains filtered or unexported fields
}

QRCode 二维码

func New

func New(ctx *config.Context) *QRCode

New New

func (*QRCode) Route

func (q *QRCode) Route(r *wkhttp.WKHttp)

Route 路由配置

Jump to

Keyboard shortcuts

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