实现新增门店奖励

This commit is contained in:
2025-06-09 09:25:11 +08:00
parent 2054256a8c
commit 7d43a89bf2
2 changed files with 198 additions and 5 deletions

View File

@ -1,11 +1,13 @@
package model
import (
"github.com/gogf/gf/v2/frame/g"
"github.com/gogf/gf/v2/os/gtime"
)
// Reward 奖励信息
type Reward struct {
g.Meta `orm:"table:rewards"`
ID int64 `json:"id" orm:"id,primary"` // 奖励ID
RewardTypeID int64 `json:"rewardTypeId" orm:"reward_type_id,not null"` // 奖励类型ID
RewardScope int `json:"rewardScope" orm:"reward_scope,not null,default:2"` // 奖励范围1=系统奖励2=门店奖励
@ -34,6 +36,8 @@ type RewardCreateIn struct {
type RewardUpdateIn struct {
ID int64 // 奖励ID
OperatorId int64 // 操作人ID
OperatorRole string // 操作人角色
RewardTypeID int64 // 奖励类型ID
RewardScope int // 奖励范围1=系统奖励2=门店奖励
Name string // 奖励名称
@ -46,6 +50,8 @@ type RewardUpdateIn struct {
}
type RewardListIn struct {
OperatorId int64 // 操作人ID
OperatorRole string // 操作人角色
Page int // 页码
Size int // 每页数量
StoreID *int64 // 门店ID用于过滤门店可见的奖励
@ -61,7 +67,9 @@ type RewardListOut struct {
}
type RewardDeleteIn struct {
ID int64 // 奖励ID
ID int64 // 奖励ID
OperatorId int64 // 操作人ID
OperatorRole string // 操作人角色
}
type RewardDetailIn struct {