mirror of
https://github.com/AlistGo/alist.git
synced 2025-05-27 18:40:01 +08:00
🚧 webdav write interface
This commit is contained in:
@ -24,34 +24,34 @@ func (driver Cloud189) Items() []Item {
|
||||
{
|
||||
Name: "username",
|
||||
Label: "username",
|
||||
Type: "string",
|
||||
Type: TypeString,
|
||||
Required: true,
|
||||
Description: "account username/phone number",
|
||||
},
|
||||
{
|
||||
Name: "password",
|
||||
Label: "password",
|
||||
Type: "string",
|
||||
Type: TypeString,
|
||||
Required: true,
|
||||
Description: "account password",
|
||||
},
|
||||
{
|
||||
Name: "root_folder",
|
||||
Label: "root folder file_id",
|
||||
Type: "string",
|
||||
Type: TypeString,
|
||||
Required: true,
|
||||
},
|
||||
{
|
||||
Name: "order_by",
|
||||
Label: "order_by",
|
||||
Type: "select",
|
||||
Type: TypeSelect,
|
||||
Values: "name,size,lastOpTime,createdDate",
|
||||
Required: true,
|
||||
},
|
||||
{
|
||||
Name: "order_direction",
|
||||
Label: "desc",
|
||||
Type: "select",
|
||||
Type: TypeSelect,
|
||||
Values: "true,false",
|
||||
Required: true,
|
||||
},
|
||||
@ -97,7 +97,7 @@ func (driver Cloud189) File(path string, account *model.Account) (*model.File, e
|
||||
return &file, nil
|
||||
}
|
||||
}
|
||||
return nil, PathNotFound
|
||||
return nil, ErrPathNotFound
|
||||
}
|
||||
|
||||
func (driver Cloud189) Files(path string, account *model.Account) ([]model.File, error) {
|
||||
@ -132,7 +132,7 @@ func (driver Cloud189) Link(path string, account *model.Account) (string, error)
|
||||
return "", err
|
||||
}
|
||||
if file.Type == conf.FOLDER {
|
||||
return "", NotFile
|
||||
return "", ErrNotFile
|
||||
}
|
||||
client, ok := client189Map[account.Name]
|
||||
if !ok {
|
||||
@ -194,7 +194,28 @@ func (driver Cloud189) Proxy(ctx *gin.Context, account *model.Account) {
|
||||
}
|
||||
|
||||
func (driver Cloud189) Preview(path string, account *model.Account) (interface{}, error) {
|
||||
return nil, NotSupport
|
||||
return nil, ErrNotSupport
|
||||
}
|
||||
|
||||
|
||||
func (driver Cloud189) MakeDir(path string, account *model.Account) error {
|
||||
return ErrNotImplement
|
||||
}
|
||||
|
||||
func (driver Cloud189) Move(src string, dst string, account *model.Account) error {
|
||||
return ErrNotImplement
|
||||
}
|
||||
|
||||
func (driver Cloud189) Copy(src string, dst string, account *model.Account) error {
|
||||
return ErrNotImplement
|
||||
}
|
||||
|
||||
func (driver Cloud189) Delete(path string, account *model.Account) error {
|
||||
return ErrNotImplement
|
||||
}
|
||||
|
||||
func (driver Cloud189) Upload(file *model.FileStream, account *model.Account) error {
|
||||
return ErrNotImplement
|
||||
}
|
||||
|
||||
var _ Driver = (*Cloud189)(nil)
|
Reference in New Issue
Block a user