product_photo.go 1.2 KB

123456789101112131415161718192021
  1. package gorm_model
  2. import (
  3. "time"
  4. )
  5. type YounggeeProductPhoto struct {
  6. ProductPhotoID int64 `gorm:"column:product_photo_id;primary_key;AUTO_INCREMENT"` // 商品图片id
  7. PhotoUrl string `gorm:"column:photo_url"` // 图片或视频url
  8. PhotoUid string `gorm:"column:photo_uid"` // uid
  9. Symbol int64 `gorm:"column:symbol"` // 图片为主图或详情图标志位,1为主图,2为详情图,3为视频
  10. ProductID int64 `gorm:"column:product_id"` // 所属商品id
  11. CreatedAt time.Time `gorm:"column:created_at"` // 创建时间
  12. StoreID int `gorm:"column:store_id"` // 所属门店ID
  13. TeamBuyingID int `gorm:"column:team_buying_id"` // 所属团购ID
  14. ProductPhotoType int `gorm:"column:product_photo_type;default:1"` // 图片类型:1商品,2门店,3团购
  15. }
  16. func (m *YounggeeProductPhoto) TableName() string {
  17. return "younggee_product_photo"
  18. }