feat: 更新用户、订单、媒体资产和租户模型,添加新的字段类型和结构体

This commit is contained in:
2025-12-29 12:01:22 +08:00
parent 0d0aee87b1
commit d648a1e45b
13 changed files with 141 additions and 92 deletions

View File

@@ -30,7 +30,7 @@ type Content struct {
PreviewDownloadable bool `gorm:"column:preview_downloadable;type:boolean" json:"preview_downloadable"`
PublishedAt time.Time `gorm:"column:published_at;type:timestamp with time zone" json:"published_at"`
Summary string `gorm:"column:summary;type:character varying(256)" json:"summary"`
Tags types.JSON `gorm:"column:tags;type:jsonb;default:[]" json:"tags"`
Tags types.JSONSlice[string] `gorm:"column:tags;type:jsonb;default:[]" json:"tags"`
Body string `gorm:"column:body;type:text" json:"body"`
Genre string `gorm:"column:genre;type:character varying(64)" json:"genre"`
Views int32 `gorm:"column:views;type:integer" json:"views"`