新功能点:首页文件上传功能可通过配置实时开启或禁用

This commit is contained in:
陈精华
2021-07-06 09:09:19 +08:00
parent dc50a460e5
commit fcdefa450c
7 changed files with 32 additions and 8 deletions

View File

@ -48,6 +48,7 @@ public class ConfigRefreshComponent {
String baseUrl;
String trustHost;
String pdfDownloadDisable;
boolean fileUploadDisable;
while (true) {
FileReader fileReader = new FileReader(configFilePath);
BufferedReader bufferedReader = new BufferedReader(fileReader);
@ -66,6 +67,7 @@ public class ConfigRefreshComponent {
baseUrl = properties.getProperty("base.url", ConfigConstants.DEFAULT_BASE_URL);
trustHost = properties.getProperty("trust.host", ConfigConstants.DEFAULT_TRUST_HOST);
pdfDownloadDisable = properties.getProperty("pdf.download.disable", ConfigConstants.DEFAULT_PDF_DOWNLOAD_DISABLE);
fileUploadDisable = Boolean.parseBoolean(properties.getProperty("file.upload.disable", ConfigConstants.DEFAULT_FILE_UPLOAD_DISABLE));
ConfigConstants.setCacheEnabledValueValue(cacheEnabled);
ConfigConstants.setSimTextValue(textArray);
ConfigConstants.setMediaValue(mediaArray);
@ -77,6 +79,7 @@ public class ConfigRefreshComponent {
ConfigConstants.setTrustHostValue(trustHost);
ConfigConstants.setOfficePreviewSwitchDisabledValue(officePreviewSwitchDisabled);
ConfigConstants.setPdfDownloadDisableValue(pdfDownloadDisable);
ConfigConstants.setFileUploadDisableValue(fileUploadDisable);
setWatermarkConfig(properties);
bufferedReader.close();
fileReader.close();