alist/internal/model/account.go

31 lines
764 B
Go
Raw Normal View History

2022-06-06 21:48:53 +08:00
package model
type Account struct {
ID uint `json:"id" gorm:"primaryKey"`
2022-06-09 17:11:46 +08:00
VirtualPath string `json:"virtual_path" gorm:"unique" binding:"required"`
2022-06-06 21:48:53 +08:00
Index int `json:"index"`
2022-06-06 22:06:33 +08:00
Driver string `json:"driver"`
2022-06-06 21:48:53 +08:00
Status string `json:"status"`
2022-06-06 22:31:56 +08:00
Addition string `json:"addition"`
2022-06-07 18:13:55 +08:00
Remark string `json:"remark"`
2022-06-07 16:38:31 +08:00
Sort
Proxy
}
type Sort struct {
OrderBy string `json:"order_by"`
OrderDirection string `json:"order_direction"`
ExtractFolder string `json:"extract_folder"`
}
type Proxy struct {
WebProxy string `json:"web_proxy"`
WebdavProxy bool `json:"webdav_proxy"`
WebdavDirect bool `json:"webdav_direct"`
DownProxyUrl string `json:"down_proxy_url"`
2022-06-06 21:48:53 +08:00
}
2022-06-08 16:20:58 +08:00
func (a Account) GetAccount() Account {
return a
}