global

package
v1.0.1 Latest Latest
Warning

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

Go to latest
Published: Nov 17, 2024 License: AGPL-3.0 Imports: 5 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

View Source
var (
	ErrInvalidParameter = errors.New("invalid parameter")
	ErrNoPermission     = errors.New("无权限")

	ErrFrequentOperation  = errors.New("操作太频繁,稍后再试")
	ErrDeviceNotSupported = errors.New("当前设备不支持")

	ErrTooManyTourists = errors.New("游客过多稍后再试")
)
View Source
var (
	ErrTimeFrameIsTooLong = errors.New("时间范围过长")

	ErrAccountId = errors.New("error accountId")
)

数据校验

View Source
var (
	GvaDb  = initialize.Db
	GvaRdb = initialize.Rdb
	Config = initialize.Config
	Cache  = initialize.Cache
)
View Source
var (
	RequestLogger *zap.Logger
	ErrorLogger   *zap.Logger
	PanicLogger   *zap.Logger
)
View Source
var ErrAccountType = errors.New("账本类型不允许该操作")

账本

View Source
var ErrCategoryNameEmpty = errors.New("名称不可为空")

交易类型

View Source
var ErrCategorySameName = errors.New("类型名称相同")
View Source
var ErrOperationTooFrequent = errors.New("操作过于频繁,请稍后再试!")
View Source
var ErrSameAsTheOldPassword = errors.New("新旧密码相同")

用户

View Source
var ErrServiceClosed = errors.New("服务未开启!")
View Source
var ErrTouristHaveNoRight = errors.New("游客无权操作!")
View Source
var ErrUnsupportedUserAction = errors.New("暂不支持该操作")

对应constant.UserAction

View Source
var ErrVerifyEmailCaptchaFail = errors.New("校验邮箱验证码失败!")

Functions

func NewErrDataIsEmpty

func NewErrDataIsEmpty(param string) error

func NewErrThirdpartyApi

func NewErrThirdpartyApi(name, msg string) error

Types

type AmountCount

type AmountCount struct {
	Amount int64
	Count  int64
}

type IEStatistic

type IEStatistic struct {
	Income  AmountCount
	Expense AmountCount
}

type IEStatisticWithTime

type IEStatisticWithTime struct {
	IEStatistic
	StartTime time.Time
	EndTime   time.Time
}

Directories

Path Synopsis

Jump to

Keyboard shortcuts

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