FinanceDeposit

package
v5.1.34 Latest Latest
Warning

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

Go to latest
Published: Apr 27, 2024 License: Apache-2.0 Imports: 15 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func DeleteConfigByMark

func DeleteConfigByMark(args *ArgsDeleteConfigByMark) (err error)

DeleteConfigByMark 删除

func GetAnalysisPrice

func GetAnalysisPrice(args *ArgsGetAnalysisPrice) (count int64, err error)

GetAnalysisPrice 储蓄账户金额

func GetConfigMoreMap

func GetConfigMoreMap(args *ArgsGetConfigMore) (data map[string]string, err error)

GetConfigMoreMap 获取一组配置名称组

func GetConfigName

func GetConfigName(mark string) (name string)

GetConfigName 获取配置名称

func GetPriceByFrom

func GetPriceByFrom(args *ArgsGetByFrom) (price int64)

GetPriceByFrom 检查来源金额是否足够?

func Run

func Run()

Run 维护

Types

type ArgsDeleteConfigByMark

type ArgsDeleteConfigByMark struct {
	//标识码
	Mark string `db:"mark" json:"mark"`
}

ArgsDeleteConfigByMark 删除参数

type ArgsGetAnalysisPrice

type ArgsGetAnalysisPrice struct {
	//存储来源
	// 如不同的加盟商,储蓄均有所差异,也可以留空不指定,则为平台总的储蓄资金池
	FromInfo CoreSQLFrom.FieldsFrom `db:"from_info" json:"fromInfo"`
	//储蓄配置标识码
	// 可用于同一类货币下,多个用途,如赠送的储值额度、或用户自行充值的额度
	// user 用户自己储值 ; deposit 押金 ; free 免费赠送额度 ; ... 特定系统下的充值模块
	ConfigMark string `db:"config_mark" json:"configMark"`
}

ArgsGetAnalysisPrice 储蓄账户金额参数

type ArgsGetByFrom

type ArgsGetByFrom struct {
	//创建来源
	CreateInfo CoreSQLFrom.FieldsFrom
	//存储来源
	FromInfo CoreSQLFrom.FieldsFrom
	//存储标识码
	ConfigMark string
}

ArgsGetByFrom 获取来源参数

type ArgsGetByID

type ArgsGetByID struct {
	//ID
	ID int64 `db:"id" json:"id"`
}

ArgsGetByID 获取某个ID参数

type ArgsGetConfigByMark

type ArgsGetConfigByMark struct {
	//标识码
	Mark string `json:"mark" check:"mark"`
}

ArgsGetConfigByMark 获取mark参数

type ArgsGetConfigList

type ArgsGetConfigList struct {
	//分页
	Pages CoreSQLPages.ArgsDataList
	//搜索
	Search string
}

ArgsGetConfigList 获取列表参数

type ArgsGetConfigMore

type ArgsGetConfigMore struct {
	//Mark列
	Marks pq.StringArray `json:"marks" check:"marks"`
}

ArgsGetConfigMore 获取一组配置参数

type ArgsGetList

type ArgsGetList struct {
	//分页
	Pages CoreSQLPages.ArgsDataList
	//创建来源
	CreateInfo CoreSQLFrom.FieldsFrom
	//存储来源
	FromInfo CoreSQLFrom.FieldsFrom
	//存储标识码
	ConfigMark string
	//最小金额
	// 0忽略
	MinPrice int64
	//最大金额
	// 0忽略
	MaxPrice int64
}

ArgsGetList 获取储蓄数据列表参数

type ArgsSetByFrom

type ArgsSetByFrom struct {
	//更新hash
	UpdateHash string
	//创建来源
	CreateInfo CoreSQLFrom.FieldsFrom
	//存储来源
	FromInfo CoreSQLFrom.FieldsFrom
	//配置标识码
	ConfigMark string
	//增减金额
	AppendSavePrice int64
}

ArgsSetByFrom 修改或创建数据参数

type ArgsSetByID

type ArgsSetByID struct {
	//更新hash
	UpdateHash string
	//ID
	ID int64
	//配置标识码
	ConfigMark string
	//增减金额
	AppendSavePrice int64
}

ArgsSetByID 修改必定存在的储蓄参数

type ArgsSetConfig

type ArgsSetConfig struct {
	//标识码
	// 可用于同一类货币下,多个用途,如赠送的储值额度、或用户自行充值的额度
	// user 用户自己储值 ; deposit 押金 ; free 免费赠送额度 ; ... 特定系统下的充值模块
	Mark string `db:"mark" json:"mark"`
	//显示名称
	Name string `db:"name" json:"name"`
	//备注
	Des string `db:"des" json:"des"`
	//储蓄货币类型
	// 采用CoreCurrency匹配
	Currency int `db:"currency" json:"currency"`
	//能否取出
	// 如果能,则允许用户使用取出接口
	TakeOut bool `db:"take_out" json:"takeOut"`
	//取款最低限额
	// 低于该资金禁止取款,同时需启动是否可取
	TakeLimit int64 `db:"take_limit" json:"takeLimit"`
	//单次存款最低限额
	OnceSaveMinLimit int64 `db:"once_save_min_limit" json:"onceSaveMinLimit"`
	//单次存款最大限额
	OnceSaveMaxLimit int64 `db:"once_save_max_limit" json:"onceSaveMaxLimit"`
	//单次取款最低限额
	OnceTakeMinLimit int64 `db:"once_take_min_limit" json:"onceTakeMinLimit"`
	//单次取款最大限额
	OnceTakeMaxLimit int64 `db:"once_take_max_limit" json:"onceTakeMaxLimit"`
	//扩展参数设计
	Configs CoreSQLConfig.FieldsConfigsType `db:"configs" json:"configs"`
}

ArgsSetConfig 保存或设置新的参数

type FieldsConfigType

type FieldsConfigType struct {
	//标识码
	// 可用于同一类货币下,多个用途,如赠送的储值额度、或用户自行充值的额度
	// user 用户自己储值 ; deposit 押金 ; free 免费赠送额度 ; ... 特定系统下的充值模块
	Mark string `db:"mark" json:"mark"`
	//显示名称
	Name string `db:"name" json:"name"`
	//备注
	Des string `db:"des" json:"des"`
	//储蓄货币类型
	// 采用CoreCurrency匹配
	Currency int `db:"currency" json:"currency"`
	//能否取出
	// 如果能,则允许用户使用取出接口
	TakeOut bool `db:"take_out" json:"takeOut"`
	//取款最低限额
	// 低于该资金禁止取款,同时需启动是否可取
	TakeLimit int64 `db:"take_limit" json:"takeLimit"`
	//单次存款最低限额
	OnceSaveMinLimit int64 `db:"once_save_min_limit" json:"onceSaveMinLimit"`
	//单次存款最大限额
	OnceSaveMaxLimit int64 `db:"once_save_max_limit" json:"onceSaveMaxLimit"`
	//单次取款最低限额
	OnceTakeMinLimit int64 `db:"once_take_min_limit" json:"onceTakeMinLimit"`
	//单次取款最大限额
	OnceTakeMaxLimit int64 `db:"once_take_max_limit" json:"onceTakeMaxLimit"`
	//扩展参数设计
	Configs CoreSQLConfig.FieldsConfigsType `db:"configs" json:"configs"`
}

FieldsConfigType 存储配置 只有平台允许设计统一的储蓄配置池,组织只能使用相关储蓄池

func GetConfigByMark

func GetConfigByMark(args *ArgsGetConfigByMark) (data FieldsConfigType, err error)

GetConfigByMark 获取mark

func GetConfigList

func GetConfigList(args *ArgsGetConfigList) (dataList []FieldsConfigType, dataCount int64, err error)

GetConfigList 获取列表

func GetConfigMore

func GetConfigMore(args *ArgsGetConfigMore) (dataList []FieldsConfigType, err error)

GetConfigMore 获取一组配置

func SetConfig

func SetConfig(args *ArgsSetConfig) (data FieldsConfigType, err error)

SetConfig 保存或设置新的

type FieldsDepositType

type FieldsDepositType struct {
	//ID
	ID int64 `db:"id" json:"id"`
	//创建时间
	CreateAt time.Time `db:"create_at" json:"createAt"`
	//更新时间
	UpdateAt time.Time `db:"update_at" json:"updateAt"`
	//HASH
	UpdateHash string `db:"update_hash" json:"updateHash"`
	//来源
	CreateInfo CoreSQLFrom.FieldsFrom `db:"create_info" json:"createInfo"`
	//存储来源
	// 如不同的加盟商,储蓄均有所差异,也可以留空不指定,则为平台总的储蓄资金池
	FromInfo CoreSQLFrom.FieldsFrom `db:"from_info" json:"fromInfo"`
	//储蓄配置标识码
	// 可用于同一类货币下,多个用途,如赠送的储值额度、或用户自行充值的额度
	// user 用户自己储值 ; deposit 押金 ; free 免费赠送额度 ; ... 特定系统下的充值模块
	ConfigMark string `db:"config_mark" json:"configMark"`
	//储蓄金额
	SavePrice int64 `db:"save_price" json:"savePrice"`
}

FieldsDepositType 储蓄资金池

func GetByFrom

func GetByFrom(args *ArgsGetByFrom) (data FieldsDepositType, err error)

GetByFrom 获取来源

func GetByID

func GetByID(args *ArgsGetByID) (data FieldsDepositType, err error)

GetByID 获取某个ID

func GetList

func GetList(args *ArgsGetList) (dataList []FieldsDepositType, dataCount int64, err error)

GetList 获取储蓄数据列表

func SetByFrom

func SetByFrom(args *ArgsSetByFrom) (data FieldsDepositType, errCode string, err error)

SetByFrom 修改或创建数据

func SetByID

func SetByID(args *ArgsSetByID) (data FieldsDepositType, errCode string, err error)

SetByID 修改必定存在的储蓄

Jump to

Keyboard shortcuts

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