weiro/models/uploads.go
Leon Mika 199ff9feb9 More changes to uploads:
- Have got upload images appearing in the post list
- Allowed for deleting uploads
- Allowed for seeing the upload progress
- Fixed the setting of upload properties like the MIME type
- Removed the stripe exif logic with just re-encoding PNGs and JPEGs by loading them and saving them
2026-03-04 22:33:39 +11:00

26 lines
723 B
Go

package models
import "time"
type Upload struct {
ID int64 `json:"id"`
SiteID int64 `json:"site_id"`
GUID string `json:"guid"`
FileSize int64 `json:"file_size"`
MIMEType string `json:"mime_type"`
Filename string `json:"filename"`
CreatedAt time.Time `json:"created_at"`
Slug string `json:"slug"`
Alt string `json:"alt"`
}
type PendingUpload struct {
GUID string `json:"guid"`
SiteID int64 `json:"site_id"`
UserID int64 `json:"user_id"`
FileSize int64 `json:"file_size"`
Filename string `json:"filename"`
MIMEType string `json:"mime_mime"`
UploadStarted time.Time `json:"upload_started"`
}