feat: add proxy_range
option for 139Yun
Alias
AList V3
(#6496)
This commit is contained in:
@ -12,6 +12,7 @@ type Config struct {
|
||||
CheckStatus bool `json:"-"`
|
||||
Alert string `json:"alert"` //info,success,warning,danger
|
||||
NoOverwriteUpload bool `json:"-"` // whether to support overwrite upload
|
||||
ProxyRangeOption bool `json:"-"`
|
||||
}
|
||||
|
||||
func (c Config) MustProxy() bool {
|
||||
|
@ -27,6 +27,7 @@ type Sort struct {
|
||||
type Proxy struct {
|
||||
WebProxy bool `json:"web_proxy"`
|
||||
WebdavPolicy string `json:"webdav_policy"`
|
||||
ProxyRange bool `json:"proxy_range"`
|
||||
DownProxyUrl string `json:"down_proxy_url"`
|
||||
}
|
||||
|
||||
|
@ -93,6 +93,17 @@ func getMainItems(config driver.Config) []driver.Item {
|
||||
Required: true,
|
||||
},
|
||||
}...)
|
||||
if config.ProxyRangeOption {
|
||||
item := driver.Item{
|
||||
Name: "proxy_range",
|
||||
Type: conf.TypeBool,
|
||||
Help: "Need to enable proxy",
|
||||
}
|
||||
if config.Name == "139Yun" {
|
||||
item.Default = "true"
|
||||
}
|
||||
items = append(items, item)
|
||||
}
|
||||
} else {
|
||||
items = append(items, driver.Item{
|
||||
Name: "webdav_policy",
|
||||
|
Reference in New Issue
Block a user