package model type Notice struct { ID int `gorm:"primaryKey;column:id" json:"id"` Title string `gorm:"column:title" json:"title"` Content string `gorm:"column:content" json:"content"` ImgURL *string `gorm:"column:img_url" json:"img_url"` Tags *string `gorm:"column:tags" json:"tags"` Show bool `gorm:"column:show" json:"show"` Popup bool `gorm:"column:popup" json:"popup"` Sort *int `gorm:"column:sort" json:"sort"` CreatedAt int64 `gorm:"column:created_at" json:"created_at"` UpdatedAt int64 `gorm:"column:updated_at" json:"updated_at"` } func (Notice) TableName() string { return "v2_notice" }