Files
bl/modules/config/model/sign.go
xinian 99748ba41e
Some checks failed
ci/woodpecker/push/my-first-workflow Pipeline failed
refactor: 重构奖励发放逻辑并支持签到默认奖励
2026-04-06 03:42:48 +08:00

35 lines
843 B
Go
Raw Blame History

This file contains ambiguous Unicode characters

This file contains Unicode characters that might be confused with other characters. If you think that this is intentional, you can safely ignore this warning. Use the Escape button to reveal them.

package model
import "blazing/cool"
const TableNameSignIn = "config_sign_in"
const (
SignTypeTotal uint32 = 1
SignTypeContinuous uint32 = 2
)
// SignIn 签到阶段配置表。
type SignIn struct {
*BaseConfig
SignType uint32 `gorm:"not null;default:1;uniqueIndex:idx_sign_type_stage;comment:'签到类别1-累计 2-连续)'" json:"sign_type"`
StageDays uint32 `gorm:"not null;default:1;uniqueIndex:idx_sign_type_stage;comment:'签到阶段天数0/1/3/7/14/30'" json:"stage_days"`
CdkID uint32 `gorm:"not null;uniqueIndex;comment:'绑定的CDK配置ID'" json:"cdk_id"`
}
func (*SignIn) TableName() string {
return TableNameSignIn
}
func (*SignIn) GroupName() string {
return "default"
}
func NewSignIn() *SignIn {
return &SignIn{BaseConfig: NewBaseConfig()}
}
func init() {
cool.CreateTable(&SignIn{})
}