67 lines
1.9 KiB
Go
67 lines
1.9 KiB
Go
package model
|
|
|
|
import (
|
|
"github.com/gogf/gf/v2/frame/g"
|
|
"github.com/gogf/gf/v2/os/gtime"
|
|
)
|
|
|
|
type SignInRewardRule struct {
|
|
g.Meta `orm:"table:sign_in_reward_rules"`
|
|
Id int64 `json:"id" orm:"id"`
|
|
RuleName string `json:"ruleName" orm:"rule_name"`
|
|
CycleDays int `json:"cycleDays" orm:"cycle_days"`
|
|
StartDate string `json:"startDate" orm:"start_date"`
|
|
EndDate string `json:"endDate" orm:"end_date"`
|
|
Status int `json:"status" orm:"status"`
|
|
CreatedAt *gtime.Time `json:"createdAt" orm:"created_at"`
|
|
UpdatedAt *gtime.Time `json:"updatedAt" orm:"updated_at"`
|
|
DeletedAt *gtime.Time `json:"deletedAt" orm:"deleted_at"`
|
|
}
|
|
|
|
type SignInRewardRulesListIn struct {
|
|
Page int `json:"page"`
|
|
Size int `json:"size"`
|
|
Status int `json:"status"`
|
|
RuleName string `json:"ruleName"`
|
|
}
|
|
type SignInRewardRulesListOut struct {
|
|
Total int `json:"total"`
|
|
List []SignInRewardRule `json:"list"`
|
|
}
|
|
|
|
type SignInRewardRulesCreateIn struct {
|
|
RuleName string `json:"ruleName"`
|
|
CycleDays int `json:"cycleDays"`
|
|
StartDate string `json:"startDate"`
|
|
EndDate string `json:"endDate"`
|
|
Status int `json:"status"`
|
|
}
|
|
type SignInRewardRulesUpdateIn struct {
|
|
Id int64 `json:"id"`
|
|
RuleName string `json:"ruleName"`
|
|
CycleDays int `json:"cycleDays"`
|
|
StartDate string `json:"startDate"`
|
|
EndDate string `json:"endDate"`
|
|
Status int `json:"status"`
|
|
}
|
|
type SignInRewardRulesDeleteIn struct {
|
|
Id int64 `json:"id"`
|
|
}
|
|
type SignInRewardRulesCRUDOut struct {
|
|
Success bool `json:"success"`
|
|
}
|
|
type SignInRewardRulesSetStatusIn struct {
|
|
Id int64 `json:"id"`
|
|
Status int `json:"status"`
|
|
}
|
|
|
|
type SignInListIn struct {
|
|
UserId int64 `json:"userId"`
|
|
}
|
|
|
|
type SignInListOut struct {
|
|
g.Meta `orm:"table:sign_in_reward_rules"`
|
|
Id int64 `json:"id" orm:"id"`
|
|
List []SignInListItem `json:"list" orm:"with:rule_id = id"`
|
|
}
|