micro-document/internel/model/press_releases.go

29 lines
1.0 KiB
Go
Raw Normal View History

2025-06-11 02:11:17 +00:00
package model
2025-06-11 05:54:38 +00:00
2025-06-18 01:33:32 +00:00
import (
"time"
"gorm.io/gorm"
)
2025-06-11 05:54:38 +00:00
type PressReleases struct {
2025-06-18 01:33:32 +00:00
ID uint `gorm:"primarykey"`
CreatedAt time.Time
UpdatedAt time.Time
DeletedAt gorm.DeletedAt `gorm:"column:deleted_at;index:idx_governance_deleted_at;uniqueIndex:governance_unique;"`
Title string `gorm:"column:title;type:varchar(100);not null;uniqueIndex:governance_unique"`
Sort uint `gorm:"not null"`
Content string `gorm:"type:longtext"`
Attachment string `gorm:"type:varchar(1024)"`
Display int `gorm:"comment:状态 1不展示 2 展示"`
Summary string `gorm:"type:text;comment:摘要"`
Status int `gorm:"comment:状态 1下架 2 上架"`
Operator string `gorm:"type:varchar(100)"`
OperatorID uint `gorm:"column:operator_id"`
AttachmentName string `gorm:"type:varchar(1024)"`
2025-06-11 05:54:38 +00:00
}
func (*PressReleases) TableName() string {
return "press_releases"
}