qudoco-be/app/database/entity/popup_news_content_image.en...

16 lines
615 B
Go
Raw Normal View History

2026-04-09 18:08:56 +00:00
package entity
type PopupNewsContentImages struct {
ID uint `json:"id" gorm:"primaryKey;autoIncrement"`
PopupNewsContentID uint `json:"popup_news_content_id"`
MediaPath string `json:"media_path" gorm:"type:varchar(255)"`
MediaURL string `json:"media_url" gorm:"type:text"`
IsThumbnail *bool `json:"is_thumbnail" gorm:"default:false"`
// 🔥 RELATION BACK (optional)
PopupNewsContents PopupNewsContents `json:"popup_news_contents" gorm:"foreignKey:PopupNewsContentID"`
}
func (PopupNewsContentImages) TableName() string {
return "popup_news_content_image"
}