- package gorm_model
- import (
- "time"
- )
- type ProjectPhoto struct {
- ProjectPhotoId int `gorm:"column:project_photo_id;type:int(11);primary_key" json:"project_photo_id"` // 项目图片id
- PhotoUrl string `gorm:"column:photo_url;type:varchar(1000)" json:"photo_url"` // 图片url
- ProjectId int `gorm:"column:project_id;type:int(11)" json:"project_id"` // 所属项目id
- CreatedAt time.Time `gorm:"column:created_at;type:datetime" json:"created_at"` // 创建时间
- }
- func (m *ProjectPhoto) TableName() string {
- return "project_photo"
- }
|