Documentation ¶
Index ¶
- func DeleteSend(args *ArgsDeleteSend) (err error)
- func Run()
- func TakeSend(args *ArgsTakeSend) (errCode string, err error)
- type ArgsCreateSend
- type ArgsDeleteSend
- type ArgsGetLogList
- type ArgsGetSendList
- type ArgsGetSendListByUser
- type ArgsTakeSend
- type DataGetSendListByUser
- type FieldsSend
- type FieldsSendLog
Constants ¶
This section is empty.
Variables ¶
This section is empty.
Functions ¶
Types ¶
type ArgsCreateSend ¶
type ArgsCreateSend struct { //组织ID OrgID int64 `db:"org_id" json:"orgID" check:"id" empty:"true"` //是否必须是会员配置ID NeedUserSubConfigID int64 `db:"need_user_sub_config_id" json:"needUserSubConfigID" check:"id" empty:"true"` //是否自动发放,如果不是,则需绑定广告 NeedAuto bool `db:"need_auto" json:"needAuto" check:"bool"` //发放的票据配置ID ConfigID int64 `db:"config_id" json:"configID" check:"id" empty:"true"` //每个用户发放几张 PerCount int64 `db:"per_count" json:"perCount" check:"int64Than0"` }
ArgsCreateSend 创建新增赠与参数
type ArgsDeleteSend ¶
type ArgsDeleteSend struct { //ID ID int64 `db:"id" json:"id" check:"id"` //组织ID OrgID int64 `db:"org_id" json:"orgID" check:"id" empty:"true"` }
ArgsDeleteSend 删除赠与参数
type ArgsGetLogList ¶
type ArgsGetLogList struct { //分页 Pages CoreSQLPages.ArgsDataList `json:"pages"` //组织ID OrgID int64 `db:"org_id" json:"orgID" check:"id" empty:"true"` //发放ID SendID int64 `db:"send_id" json:"sendID" check:"id"` }
ArgsGetLogList 查看发放日志参数
type ArgsGetSendList ¶
type ArgsGetSendList struct { //分页 Pages CoreSQLPages.ArgsDataList `json:"pages"` //组织ID OrgID int64 `db:"org_id" json:"orgID" check:"id" empty:"true"` //发放的票据配置ID ConfigID int64 `db:"config_id" json:"configID" check:"id" empty:"true"` //是否自动发放,如果不是,则需绑定广告 NeedAuto bool `db:"need_auto" json:"needAuto" check:"bool" empty:"true"` IsAuto bool `db:"is_auto" json:"isAuto" check:"bool" empty:"true"` //是否已经领取完成 NeedIsFinish bool `json:"needIsFinish" check:"bool" empty:"true"` IsFinish bool `json:"isFinish" check:"bool" empty:"true"` }
ArgsGetSendList 获取批量给予列表参数
type ArgsGetSendListByUser ¶
type ArgsGetSendListByUser struct { //组织ID OrgID int64 `db:"org_id" json:"orgID" check:"id" empty:"true"` //用户ID UserID int64 `db:"user_id" json:"userID" check:"id"` }
ArgsGetSendListByUser 获取用户可领取的票据列表参数
type ArgsTakeSend ¶
type ArgsTakeSend struct { //组织ID OrgID int64 `db:"org_id" json:"orgID" check:"id" empty:"true"` //用户ID UserID int64 `db:"user_id" json:"userID" check:"id"` //要领取的SendID SendID int64 `db:"send_id" json:"sendID" check:"id"` }
ArgsTakeSend 领取优惠券参数
type DataGetSendListByUser ¶
type DataGetSendListByUser struct { //发放ID ID int64 `db:"id" json:"id"` //组织ID OrgID int64 `db:"org_id" json:"orgID" check:"id" empty:"true"` //发放的票据配置ID ConfigID int64 `db:"config_id" json:"configID"` //是否必须是会员配置ID NeedUserSubConfigID int64 `db:"need_user_sub_config_id" json:"needUserSubConfigID"` //是否自动发放,如果不是,则需绑定广告 NeedAuto bool `db:"need_auto" json:"needAuto"` //每个用户发放几张 PerCount int64 `db:"per_count" json:"perCount"` }
DataGetSendListByUser 获取用户可领取的票据列表数据
func GetSendListByUser ¶
func GetSendListByUser(args *ArgsGetSendListByUser) (dataList []DataGetSendListByUser, err error)
GetSendListByUser 获取用户可领取的票据列表
type FieldsSend ¶
type FieldsSend struct { //ID ID int64 `db:"id" json:"id"` //创建时间 CreateAt time.Time `db:"create_at" json:"createAt"` //完成时间 FinishAt time.Time `db:"finish_at" json:"finishAt"` //组织ID OrgID int64 `db:"org_id" json:"orgID"` //完成发放用户个数 SendCount int64 `db:"send_count" json:"sendCount"` //是否必须是会员配置ID NeedUserSubConfigID int64 `db:"need_user_sub_config_id" json:"needUserSubConfigID"` //是否自动发放,如果不是,则需绑定广告 NeedAuto bool `db:"need_auto" json:"needAuto"` //发放的票据配置ID ConfigID int64 `db:"config_id" json:"configID"` //每个用户发放几张 PerCount int64 `db:"per_count" json:"perCount"` }
FieldsSend 群发优惠券约定
func CreateSend ¶
func CreateSend(args *ArgsCreateSend) (data FieldsSend, err error)
CreateSend 创建新增赠与
func GetSendList ¶
func GetSendList(args *ArgsGetSendList) (dataList []FieldsSend, dataCount int64, err error)
GetSendList 获取批量给予列表
type FieldsSendLog ¶
type FieldsSendLog struct { //ID ID int64 `db:"id" json:"id"` //创建时间 CreateAt time.Time `db:"create_at" json:"createAt"` //发放ID SendID int64 `db:"send_id" json:"sendID"` //用户ID UserID int64 `db:"user_id" json:"userID"` }
FieldsSendLog 发放记录表 内部记录发放数据,确保不会重发 send为finish时,将在30天后删除所有记录,避免占用资源
func GetLogList ¶
func GetLogList(args *ArgsGetLogList) (dataList []FieldsSendLog, dataCount int64, err error)
GetLogList 查看发放日志
Click to show internal directories.
Click to hide internal directories.