38 lines
478 B
Go
38 lines
478 B
Go
|
package schema
|
||
|
|
||
|
import "time"
|
||
|
|
||
|
type ShareType = int
|
||
|
|
||
|
const (
|
||
|
ShareDrop = iota
|
||
|
ShareSendSingle
|
||
|
ShareSendMultiple
|
||
|
)
|
||
|
|
||
|
type MimeType = int
|
||
|
|
||
|
const (
|
||
|
MimeTypeText = iota
|
||
|
)
|
||
|
|
||
|
type Share struct {
|
||
|
ShareId int
|
||
|
ShareType ShareType
|
||
|
CreatedAt time.Time
|
||
|
ValidUntil time.Time
|
||
|
PasswordHash string
|
||
|
ManagementToken string
|
||
|
Enabled bool
|
||
|
}
|
||
|
|
||
|
type ShareFile struct {
|
||
|
ShareId int
|
||
|
Filename string
|
||
|
Mimetype MimeType
|
||
|
FileHash string
|
||
|
UploadedAt time.Time
|
||
|
Deleted bool
|
||
|
DownloadCount int
|
||
|
}
|