新增奖励回调接口,调整奖励领取接口

This commit is contained in:
chy
2025-06-25 20:57:41 +08:00
parent 853ee2190a
commit ecee39efff
33 changed files with 679 additions and 179 deletions

View File

@ -0,0 +1,26 @@
// =================================================================================
// Code generated and maintained by GoFrame CLI tool. DO NOT EDIT.
// =================================================================================
package do
import (
"github.com/gogf/gf/v2/frame/g"
"github.com/gogf/gf/v2/os/gtime"
)
// Notices is the golang structure of table notices for DAO operations like Where/Data.
type Notices struct {
g.Meta `orm:"table:notices, do:true"`
Id interface{} // 通知ID
Title interface{} // 通知标题
Content interface{} // 通知内容
Type interface{} // 通知类型1=系统公告2=活动通知3=维护通知
Status interface{} // 状态0=关闭1=发布
VisibleTo interface{} // 可见范围1=所有人2=仅门店3=仅用户
MerchantId interface{} // 所属商户ID
StoreId interface{} // 所属门店ID
CreatedAt *gtime.Time // 创建时间
UpdatedAt *gtime.Time // 更新时间
DeletedAt *gtime.Time // 软删除时间戳
}

View File

@ -0,0 +1,23 @@
// =================================================================================
// Code generated and maintained by GoFrame CLI tool. DO NOT EDIT.
// =================================================================================
package do
import (
"github.com/gogf/gf/v2/frame/g"
)
// RewardCallback is the golang structure of table reward_callback for DAO operations like Where/Data.
type RewardCallback struct {
g.Meta `orm:"table:reward_callback, do:true"`
Id interface{} //
Uid interface{} // 用户账号
OrderId interface{} // 订单号必须保证全局唯一(保证接口幂等)
PrizeChannelId interface{} // 券渠道 ID
PrizeId interface{} // 券 ID
PrizeType interface{} // 奖励类型1 网鱼积分2 网鱼经验值3 网鱼兑换码
PrizeSubType interface{} // 奖励子类型,默认为 0有多种子类型时可用如 1,5 元网费充值券2、满 30-5 满减券等
Num interface{} // 奖励个数,默认 1比如经验值 10
CustomInfo interface{} // 透传字段 (json串)
}

View File

@ -0,0 +1,24 @@
// =================================================================================
// Code generated and maintained by GoFrame CLI tool. DO NOT EDIT.
// =================================================================================
package entity
import (
"github.com/gogf/gf/v2/os/gtime"
)
// Notices is the golang structure for table notices.
type Notices struct {
Id int64 `json:"id" orm:"id" description:"通知ID"` // 通知ID
Title string `json:"title" orm:"title" description:"通知标题"` // 通知标题
Content string `json:"content" orm:"content" description:"通知内容"` // 通知内容
Type int `json:"type" orm:"type" description:"通知类型1=系统公告2=活动通知3=维护通知"` // 通知类型1=系统公告2=活动通知3=维护通知
Status int `json:"status" orm:"status" description:"状态0=关闭1=发布"` // 状态0=关闭1=发布
VisibleTo int `json:"visibleTo" orm:"visible_to" description:"可见范围1=所有人2=仅门店3=仅用户"` // 可见范围1=所有人2=仅门店3=仅用户
MerchantId int64 `json:"merchantId" orm:"merchant_id" description:"所属商户ID"` // 所属商户ID
StoreId int64 `json:"storeId" orm:"store_id" description:"所属门店ID"` // 所属门店ID
CreatedAt *gtime.Time `json:"createdAt" orm:"created_at" description:"创建时间"` // 创建时间
UpdatedAt *gtime.Time `json:"updatedAt" orm:"updated_at" description:"更新时间"` // 更新时间
DeletedAt *gtime.Time `json:"deletedAt" orm:"deleted_at" description:"软删除时间戳"` // 软删除时间戳
}

View File

@ -0,0 +1,18 @@
// =================================================================================
// Code generated and maintained by GoFrame CLI tool. DO NOT EDIT.
// =================================================================================
package entity
// RewardCallback is the golang structure for table reward_callback.
type RewardCallback struct {
Id int64 `json:"id" orm:"id" description:""` //
Uid string `json:"uid" orm:"uid" description:"用户账号"` // 用户账号
OrderId string `json:"orderId" orm:"order_id" description:"订单号必须保证全局唯一(保证接口幂等)"` // 订单号必须保证全局唯一(保证接口幂等)
PrizeChannelId string `json:"prizeChannelId" orm:"prize_channel_id" description:"券渠道 ID"` // 券渠道 ID
PrizeId string `json:"prizeId" orm:"prize_id" description:"券 ID"` // 券 ID
PrizeType int `json:"prizeType" orm:"prize_type" description:"奖励类型1 网鱼积分2 网鱼经验值3 网鱼兑换码"` // 奖励类型1 网鱼积分2 网鱼经验值3 网鱼兑换码
PrizeSubType int `json:"prizeSubType" orm:"prize_sub_type" description:"奖励子类型,默认为 0有多种子类型时可用如 1,5 元网费充值券2、满 30-5 满减券等"` // 奖励子类型,默认为 0有多种子类型时可用如 1,5 元网费充值券2、满 30-5 满减券等
Num int `json:"num" orm:"num" description:"奖励个数,默认 1比如经验值 10"` // 奖励个数,默认 1比如经验值 10
CustomInfo string `json:"customInfo" orm:"custom_info" description:"透传字段 (json串)"` // 透传字段 (json串)
}

View File

@ -123,26 +123,37 @@ type RewardListOut struct {
// RewardCallbackIn 任务奖励领取回调入参
type RewardCallbackIn struct {
AreaId int
GameId int
RewradTypeId []int
RoleIdx string
TaskId string
Uid string `json:"uid" ` // 用户账号
OrderId string `json:"orderId"` // 订单号必须保证全局唯一(保证接口幂等)
PrizeChannelId string `json:"prizeChannelId"` // 券渠道 ID
PrizeId string `json:"prizeId"` // 券 ID
PrizeType int `json:"prizeType"` // 奖励类型1 网鱼积分2 网鱼经验值3 网鱼兑换码
PrizeSubType int `json:"prizeSubType"` // 奖励子类型,默认为 0有多种子类型时可用如 1,5 元网费充值券2、满 30-5 满减券等
Num int `json:"num"` // 奖励个数,默认 1比如经验值 10
CustomInfo string `json:"customInfo"` // 透传字段 (json串)
}
type RewardCallbackOut struct {
List interface{} `json:"list"`
Result int64 `json:"result"`
Water Water `json:"water"`
Errcode int32 `json:"errcode"`
Errmsg string `json:"errmsg"`
AppId string `json:"appid"`
OrderId string `json:"order_id"`
Datas []CallbackData `json:"data"`
}
type CallbackData struct {
PrizeCode string `json:"prize_code"`
Comment string `json:"comment"`
}
type GetRewardIn struct {
AreaId int
GameId int
RewradTypeId []int
RewradTypeId int
RoleIdx string
TaskId string
PopenId string
Source int
}
type GetRewardOut struct {
List interface{} `json:"list"`