gamelife 自定义客户端集成游戏任务接口
This commit is contained in:
@ -9,8 +9,7 @@ type ListReq struct {
|
||||
Size int `json:"size" dc:"每页数量"`
|
||||
Status int `json:"status" dc:"状态"`
|
||||
StoreId int64 `json:"storeId" dc:"门店ID"`
|
||||
OperatorRole int `json:"operatorRole" dc:"操作者角色"`
|
||||
OperatorId int64 `json:"operatorId" dc:"操作者ID"`
|
||||
RewardTypeId int64 `json:"rewardTypeId" dc:"奖励类型ID"`
|
||||
}
|
||||
|
||||
type ListRes struct {
|
||||
@ -27,8 +26,6 @@ type CreateReq struct {
|
||||
StoreId int64 `json:"storeId" dc:"门店ID"`
|
||||
RewardTypeId int64 `json:"rewardTypeId" v:"required#奖励类型ID不能为空" dc:"奖励类型ID"`
|
||||
Source int `json:"source" v:"in:1,2#来源只能为1或2" dc:"来源"`
|
||||
OperatorRole int `json:"operatorRole" dc:"操作者角色"`
|
||||
OperatorId int64 `json:"operatorId" dc:"操作者ID"`
|
||||
}
|
||||
|
||||
type CreateRes struct {
|
||||
@ -36,15 +33,13 @@ type CreateRes struct {
|
||||
}
|
||||
|
||||
type UpdateReq struct {
|
||||
g.Meta `path:"/reward" method:"put" tags:"Reward" summary:"(系统、商户、门店后台)更新奖励"`
|
||||
Id int64 `json:"id" v:"required#ID不能为空" dc:"ID"`
|
||||
Name string `json:"name" v:"required#名称不能为空" dc:"名称"`
|
||||
Description string `json:"description" v:"required#描述不能为空" dc:"描述"`
|
||||
Value int64 `json:"value" v:"required#数值不能为空" dc:"奖励值"`
|
||||
Status int `json:"status" dc:"状态" d:"1"`
|
||||
StoreId int64 `json:"storeId" dc:"门店ID"`
|
||||
OperatorRole int `json:"operatorRole" dc:"操作者角色"`
|
||||
OperatorId int64 `json:"operatorId" dc:"操作者ID"`
|
||||
g.Meta `path:"/reward" method:"put" tags:"Reward" summary:"(系统、商户、门店后台)更新奖励"`
|
||||
Id int64 `json:"id" v:"required#ID不能为空" dc:"ID"`
|
||||
Name string `json:"name" v:"required#名称不能为空" dc:"名称"`
|
||||
Description string `json:"description" v:"required#描述不能为空" dc:"描述"`
|
||||
Value int64 `json:"value" v:"required#数值不能为空" dc:"奖励值"`
|
||||
Status int `json:"status" dc:"状态" d:"1"`
|
||||
StoreId int64 `json:"storeId" dc:"门店ID"`
|
||||
}
|
||||
|
||||
type UpdateRes struct {
|
||||
@ -52,10 +47,8 @@ type UpdateRes struct {
|
||||
}
|
||||
|
||||
type DeleteReq struct {
|
||||
g.Meta `path:"/reward/{id}" method:"delete" tags:"Reward" summary:"(系统、商户、门店后台)删除奖励"`
|
||||
Id int64 `in:"path" json:"id" v:"required#ID不能为空" dc:"ID"`
|
||||
OperatorRole int `json:"operatorRole" dc:"操作者角色"`
|
||||
OperatorId int64 `json:"operatorId" dc:"操作者ID"`
|
||||
g.Meta `path:"/reward/{id}" method:"delete" tags:"Reward" summary:"(系统、商户、门店后台)删除奖励"`
|
||||
Id int64 `in:"path" json:"id" v:"required#ID不能为空" dc:"ID"`
|
||||
}
|
||||
|
||||
type DeleteRes struct {
|
||||
|
||||
16
api/storeTaskReward/storeTaskReward.go
Normal file
16
api/storeTaskReward/storeTaskReward.go
Normal file
@ -0,0 +1,16 @@
|
||||
// =================================================================================
|
||||
// Code generated and maintained by GoFrame CLI tool. DO NOT EDIT.
|
||||
// =================================================================================
|
||||
|
||||
package storeTaskReward
|
||||
|
||||
import (
|
||||
"context"
|
||||
|
||||
"server/api/storeTaskReward/v1"
|
||||
)
|
||||
|
||||
type IStoreTaskRewardV1 interface {
|
||||
Create(ctx context.Context, req *v1.CreateReq) (res *v1.CreateRes, err error)
|
||||
Delete(ctx context.Context, req *v1.DeleteReq) (res *v1.DeleteRes, err error)
|
||||
}
|
||||
22
api/storeTaskReward/v1/storeTaskReward.go
Normal file
22
api/storeTaskReward/v1/storeTaskReward.go
Normal file
@ -0,0 +1,22 @@
|
||||
package v1
|
||||
|
||||
import "github.com/gogf/gf/v2/frame/g"
|
||||
|
||||
type CreateReq struct {
|
||||
g.Meta `path:"/storeTaskReward" method:"post" tags:"StoreTaskReward" summary:"(商户、门店后台)创建门店任务奖励"`
|
||||
TaskId int64 `json:"taskId" v:"required#门店任务ID不能为空" dc:"门店任务ID"`
|
||||
RewardId int64 `json:"rewardId" v:"required#奖励ID不能为空" dc:"奖励ID"`
|
||||
StoreId int64 `json:"storeId" v:"required#门店ID不能为空" dc:"门店ID"`
|
||||
}
|
||||
|
||||
type CreateRes struct {
|
||||
Id int64 `json:"id"`
|
||||
}
|
||||
|
||||
type DeleteReq struct {
|
||||
g.Meta `path:"/storeTaskReward/{id}" method:"delete" tags:"StoreTaskReward" summary:"(商户、门店后台)删除门店任务奖励"`
|
||||
Id int64 `in:"path" json:"id" v:"required#门店任务奖励ID不能为空" dc:"门店任务奖励ID"`
|
||||
}
|
||||
type DeleteRes struct {
|
||||
Success bool `json:"success" dc:"是否成功"`
|
||||
}
|
||||
Reference in New Issue
Block a user