21 lines
609 B
Go
21 lines
609 B
Go
package images
|
|
|
|
import (
|
|
"time"
|
|
)
|
|
|
|
type Image struct {
|
|
ID uint `gorm:"primaryKey" json:"id"`
|
|
UserID uint `gorm:"index;not null" json:"user_id"`
|
|
Filename string `gorm:"not null" json:"filename"`
|
|
PublicPath string `gorm:"not null" json:"public_path"`
|
|
MimeType string `gorm:"not null" json:"mime_type"`
|
|
Size int64 `json:"size"`
|
|
Width int `json:"width"`
|
|
Height int `json:"height"`
|
|
Quality int `json:"quality"`
|
|
Format string `json:"format"`
|
|
Mode string `json:"mode"`
|
|
CreatedAt time.Time `json:"created_at"`
|
|
}
|