MarketGivingUserSub

package
v5.1.39 Latest Latest
Warning

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

Go to latest
Published: Jun 6, 2024 License: Apache-2.0 Imports: 12 Imported by: 0

Documentation

Index

Constants

This section is empty.

Variables

This section is empty.

Functions

func CheckConfigAndOrg

func CheckConfigAndOrg(args *ArgsCheckConfigAndOrg) (err error)

CheckConfigAndOrg 检查配置和商户是否关联

func CreateLog

func CreateLog(args *ArgsCreateLog) (errCode string, err error)

CreateLog 创建新的请求 注意,如果多个相同订阅,则以最大符合单位个数的为基准赠送

func DeleteConditions

func DeleteConditions(args *ArgsDeleteConditions) (err error)

DeleteConditions 删除条件

func GetConditionsMoreMap

func GetConditionsMoreMap(args *ArgsGetConditionsMoreMap) (data map[int64]string, err error)

GetConditionsMoreMap 获取一组配置名称组

func UpdateConditions

func UpdateConditions(args *ArgsUpdateConditions) (err error)

UpdateConditions 修改条件

Types

type ArgsCheckConfigAndOrg

type ArgsCheckConfigAndOrg struct {
	//ID
	ID int64 `db:"id" json:"id" check:"id"`
	//组织ID
	// 可选
	OrgID int64 `db:"org_id" json:"orgID" check:"id" empty:"true"`
}

ArgsCheckConfigAndOrg 检查配置和商户是否关联参数

type ArgsCreateConditions

type ArgsCreateConditions struct {
	//组织ID
	OrgID int64 `db:"org_id" json:"orgID" check:"id"`
	//名称
	Name string `db:"name" json:"name" check:"title" min:"1" max:"300"`
	//赠礼配置ID
	ConfigID int64 `db:"config_id" json:"configID" check:"id"`
	//订阅ID
	SubConfigID int64 `db:"sub_config_id" json:"subConfigID" check:"id"`
	//订阅单位
	SubBuyCount int64 `db:"sub_buy_count" json:"subBuyCount" check:"int64Than0"`
	//扩展参数
	Params CoreSQLConfig.FieldsConfigsType `db:"params" json:"params"`
}

ArgsCreateConditions 创建条件参数

type ArgsCreateLog

type ArgsCreateLog struct {
	//组织ID
	OrgID int64 `db:"org_id" json:"orgID" check:"id"`
	//奖励的用户ID
	UserID int64 `db:"user_id" json:"userID" check:"id"`
	//推荐人用户ID
	ReferrerUserID int64 `db:"referrer_user_id" json:"referrerUserID" check:"id" empty:"true"`
	//推荐成员ID
	ReferrerBindID int64 `db:"referrer_bind_id" json:"referrerBindID" check:"id" empty:"true"`
	//交易的金额
	// 用户发生交易的总金额
	PriceTotal int64 `db:"price_total" json:"priceTotal" check:"price" empty:"true"`
	//订阅ID
	SubConfigID int64 `db:"sub_config_id" json:"subConfigID" check:"id"`
	//订阅单位
	SubBuyCount int64 `db:"sub_buy_count" json:"subBuyCount" check:"int64Than0"`
	//锁定赠礼ID
	LockGivingUserSubID int64 `db:"lock_giving_user_sub_id" json:"lockGivingUserSubID"`
}

ArgsCreateLog 创建新的请求参数

type ArgsDeleteConditions

type ArgsDeleteConditions struct {
	//ID
	ID int64 `db:"id" json:"id" check:"id"`
	//组织ID
	// 可选
	OrgID int64 `db:"org_id" json:"orgID" check:"id" empty:"true"`
}

ArgsDeleteConditions 删除条件参数

type ArgsGetConditionsList

type ArgsGetConditionsList struct {
	//分页
	Pages CoreSQLPages.ArgsDataList `json:"pages"`
	//组织ID
	OrgID int64 `db:"org_id" json:"orgID" check:"id" empty:"true"`
	//关联的奖励
	ConfigID int64 `db:"config_id" json:"configID" check:"id" empty:"true"`
	//是否被删除
	IsRemove bool `db:"is_remove" json:"isRemove" check:"bool" empty:"true"`
	//搜索
	Search string `json:"search" check:"search" empty:"true"`
}

ArgsGetConditionsList 获取条件列表参数

type ArgsGetConditionsMoreMap

type ArgsGetConditionsMoreMap struct {
	//ID列
	IDs pq.Int64Array `json:"ids"`
	//是否包含删除数据
	HaveRemove bool `json:"haveRemove"`
}

ArgsGetConditionsMoreMap 获取一组配置参数

type ArgsUpdateConditions

type ArgsUpdateConditions struct {
	//ID
	ID int64 `db:"id" json:"id" check:"id"`
	//组织ID
	// 可选
	OrgID int64 `db:"org_id" json:"orgID" check:"id" empty:"true"`
	//名称
	Name string `db:"name" json:"name" check:"title" min:"1" max:"300"`
	//赠礼配置ID
	ConfigID int64 `db:"config_id" json:"configID" check:"id"`
	//订阅ID
	SubConfigID int64 `db:"sub_config_id" json:"subConfigID" check:"id"`
	//订阅单位
	SubBuyCount int64 `db:"sub_buy_count" json:"subBuyCount" check:"int64Than0"`
	//扩展参数
	Params CoreSQLConfig.FieldsConfigsType `db:"params" json:"params"`
}

ArgsUpdateConditions 修改条件参数

type FieldsConditions

type FieldsConditions struct {
	//ID
	ID int64 `db:"id" json:"id"`
	//创建时间
	CreateAt time.Time `db:"create_at" json:"createAt"`
	//更新时间
	UpdateAt time.Time `db:"update_at" json:"updateAt"`
	//删除时间
	DeleteAt time.Time `db:"delete_at" json:"deleteAt"`
	//组织ID
	OrgID int64 `db:"org_id" json:"orgID"`
	//名称
	Name string `db:"name" json:"name"`
	//赠礼配置ID
	ConfigID int64 `db:"config_id" json:"configID"`
	//订阅配置ID
	SubConfigID int64 `db:"sub_config_id" json:"subConfigID"`
	//订阅单位
	SubBuyCount int64 `db:"sub_buy_count" json:"subBuyCount"`
	//扩展参数
	Params CoreSQLConfig.FieldsConfigsType `db:"params" json:"params"`
}

FieldsConditions 赠送条件配置

func CreateConditions

func CreateConditions(args *ArgsCreateConditions) (data FieldsConditions, err error)

CreateConditions 创建条件

func GetConditionsList

func GetConditionsList(args *ArgsGetConditionsList) (dataList []FieldsConditions, dataCount int64, err error)

GetConditionsList 获取条件列表

Jump to

Keyboard shortcuts

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