2022-03-09 16:37:03 +08:00
|
|
|
package model
|
|
|
|
|
|
|
|
type PersionDownloadDBModel struct {
|
|
|
|
UUID string `gorm:"column:uuid;primary_key" json:"uuid"`
|
2022-03-16 15:41:14 +08:00
|
|
|
State int `json:"state"` //
|
|
|
|
Type int `json:"type"` //defult 1
|
|
|
|
Name string `json:"name"` //file name
|
|
|
|
Size int64 `json:"size"` //file size
|
|
|
|
BlockSize int `json:"block_size"`
|
2022-03-09 16:37:03 +08:00
|
|
|
Length int `json:"length"` //slice length
|
|
|
|
Hash string `json:"hash"`
|
2022-03-18 11:13:07 +08:00
|
|
|
Error string `json:"error"`
|
|
|
|
From string `json:"from"`
|
|
|
|
Already int `json:"already" gorm:"-"`
|
2022-03-16 15:41:14 +08:00
|
|
|
CreatedAt int64 `gorm:"autoCreateTime" json:"created_at"`
|
|
|
|
UpdatedAt int64 `gorm:"autoCreateTime;autoUpdateTime" json:"updated_at"`
|
2022-03-09 16:37:03 +08:00
|
|
|
}
|
|
|
|
|
|
|
|
func (p *PersionDownloadDBModel) TableName() string {
|
|
|
|
return "o_persion_download"
|
|
|
|
}
|