wallet

package
v1.7.3 Latest Latest
Warning

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

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

Documentation

Overview

Package wallet 货币系统

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func GetWalletName

func GetWalletName() string

GetWalletName 获取货币名称

func GetWalletOf

func GetWalletOf(uid int64) (money int)

GetWalletOf 获取钱包数据

func InsertWalletOf

func InsertWalletOf(uid int64, money int) error

InsertWalletOf 更新钱包(money > 0 增加,money < 0 减少)

func SetWalletName

func SetWalletName(name string)

SetWalletName 设置货币名称

Types

type Storage

type Storage struct {
	sync.RWMutex
	// contains filtered or unexported fields
}

Storage 货币系统

type Wallet

type Wallet struct {
	UID   int64
	Money int
}

Wallet 钱包

func GetGroupWalletOf

func GetGroupWalletOf(sortable bool, uids ...int64) (wallets []Wallet, err error)

GetGroupWalletOf 获取多人钱包数据

if sort == true,由高到低排序; if sort == false,由低到高排序

Jump to

Keyboard shortcuts

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