validator

package
v1.0.9 Latest Latest
Warning

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

Go to latest
Published: Mar 13, 2021 License: Apache-2.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

View Source
const (
	ValidatorKey  = "ValidatorKey"
	TranslatorKey = "TranslatorKey"
)

Variables

This section is empty.

Functions

func GetTranslation

func GetTranslation(ctx *gin.Context) (ut.Translator, error)
 =================================================================
	获取翻译器
 * =================================================================

func GetValidator

func GetValidator(ctx *gin.Context) (*validator.Validate, error)
 =================================================================
	从 gin中 获取 验证器
 * =================================================================

func ParseParamsAndValidate

func ParseParamsAndValidate(ctx *gin.Context, params interface{}) error

Types

This section is empty.

Jump to

Keyboard shortcuts

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