mirror of
https://github.com/zfile-dev/zfile.git
synced 2025-04-19 05:34:52 +00:00
feature: 新增 webdav 开关功能
This commit is contained in:
@@ -15,6 +15,7 @@ import io.milton.http.HttpManager;
|
||||
import lombok.extern.slf4j.Slf4j;
|
||||
import org.slf4j.Logger;
|
||||
import org.slf4j.LoggerFactory;
|
||||
import org.springframework.boot.autoconfigure.condition.ConditionalOnProperty;
|
||||
|
||||
import java.util.Collections;
|
||||
import java.util.Date;
|
||||
@@ -28,6 +29,7 @@ import java.util.List;
|
||||
*/
|
||||
@Slf4j
|
||||
@ResourceController
|
||||
@ConditionalOnProperty(value = "webdav.enable", havingValue = "true")
|
||||
public class WebDavController {
|
||||
private static final Logger LOGGER = LoggerFactory.getLogger(WebDavController.class);
|
||||
|
||||
|
||||
@@ -97,6 +97,11 @@
|
||||
"type": "java.lang.String",
|
||||
"defaultValue": "directlink",
|
||||
"description": "直链前缀名称, 默认为 directlink"
|
||||
},
|
||||
{
|
||||
"name": "zfile.webdav",
|
||||
"type": "java.lang.Boolean",
|
||||
"description": "是否开启 webdav 文件管理."
|
||||
}
|
||||
]
|
||||
}
|
||||
@@ -1,5 +1,6 @@
|
||||
zfile:
|
||||
debug: false
|
||||
webdav: false
|
||||
directLinkPrefix: directlink
|
||||
log:
|
||||
path: ${user.home}/.zfile/logs
|
||||
@@ -80,4 +81,4 @@ spring:
|
||||
continue-on-error: true
|
||||
mode: always
|
||||
data-locations: classpath*:db/data.sql
|
||||
encoding: utf-8
|
||||
encoding: utf-8
|
||||
Reference in New Issue
Block a user