优化表结构,重构模型,重新实现基于白银网关的提取节点流程
This commit is contained in:
19
web/models/resource_long.go
Normal file
19
web/models/resource_long.go
Normal file
@@ -0,0 +1,19 @@
|
||||
package models
|
||||
|
||||
import (
|
||||
"time"
|
||||
)
|
||||
|
||||
// ResourceLong 长效动态套餐表
|
||||
type ResourceLong struct {
|
||||
ID int32 `json:"id" gorm:"column:id"` // ID
|
||||
ResourceID int32 `json:"resource_id" gorm:"column:resource_id"` // 套餐ID
|
||||
Type ResourceMode `json:"type" gorm:"column:type"` // 套餐类型:1-包时,2-包量
|
||||
Live int32 `json:"live" gorm:"column:live"` // 可用时长(天)
|
||||
Expire *time.Time `json:"expire" gorm:"column:expire"` // 过期时间
|
||||
Quota *int32 `json:"quota" gorm:"column:quota"` // 配额数量
|
||||
Used int32 `json:"used" gorm:"column:used"` // 已用数量
|
||||
DailyLimit int32 `json:"daily_limit" gorm:"column:daily_limit"` // 每日限制
|
||||
DailyUsed int32 `json:"daily_used" gorm:"column:daily_used"` // 今日已用数量
|
||||
DailyLast *time.Time `json:"daily_last" gorm:"column:daily_last"` // 今日最后使用时间
|
||||
}
|
||||
Reference in New Issue
Block a user