entity.go 1.1 KB

1234567891011121314151617181920212223242526272829
  1. package voice_broadcast_img
  2. import "time"
  3. // YbVoiceBroadcastImg 语音播报图片表
  4. type YbVoiceBroadcastImg struct {
  5. Id int `gorm:"primaryKey;column:id;type:int(10) unsigned;not null" json:"-"`
  6. BroadcastId int `gorm:"index:idx_broadcast_id;column:broadcast_id;type:int(10) unsigned;not null;default:0" json:"broadcastId"` // 语音播报ID
  7. ImgUrl string `gorm:"column:img_url;type:varchar(255);not null;default:''" json:"imgUrl"` // 图片
  8. CreateTime time.Time `gorm:"column:create_time;type:datetime" json:"createTime"` // 创建时间
  9. }
  10. // TableName get sql table name.获取数据库表名
  11. func (m *YbVoiceBroadcastImg) TableName() string {
  12. return "yb_voice_broadcast_img"
  13. }
  14. // YbVoiceBroadcastImgColumns get sql column name.获取数据库列名
  15. var YbVoiceBroadcastImgColumns = struct {
  16. ID string
  17. BroadcastID string
  18. ImgURL string
  19. CreateTime string
  20. }{
  21. ID: "id",
  22. BroadcastID: "broadcast_id",
  23. ImgURL: "img_url",
  24. CreateTime: "create_time",
  25. }