From 9a224d216652ef2d6ff2e0bd01fba69c86a3f277 Mon Sep 17 00:00:00 2001 From: yanzhaofeige <yanzhaofeige@qq.com> Date: Fri, 11 Oct 2024 11:28:55 +0800 Subject: [PATCH] 基础表单更新 --- cpzidc-admin/src/main/java/com/odcc/cpzidc/web/controller/common/CommonController.java | 10 +++++----- 1 files changed, 5 insertions(+), 5 deletions(-) diff --git a/cpzidc-admin/src/main/java/com/odcc/cpzidc/web/controller/common/CommonController.java b/cpzidc-admin/src/main/java/com/odcc/cpzidc/web/controller/common/CommonController.java index fd1bc90..e40bff4 100644 --- a/cpzidc-admin/src/main/java/com/odcc/cpzidc/web/controller/common/CommonController.java +++ b/cpzidc-admin/src/main/java/com/odcc/cpzidc/web/controller/common/CommonController.java @@ -13,7 +13,7 @@ import org.springframework.web.bind.annotation.RequestMapping; import org.springframework.web.bind.annotation.RestController; import org.springframework.web.multipart.MultipartFile; -import com.odcc.cpzidc.common.config.RuoYiConfig; +import com.odcc.cpzidc.common.config.CpzIdcConfig; import com.odcc.cpzidc.common.constant.Constants; import com.odcc.cpzidc.common.core.domain.AjaxResult; import com.odcc.cpzidc.common.utils.StringUtils; @@ -53,7 +53,7 @@ throw new Exception(StringUtils.format("文件名称({})非法,不允许下载。 ", fileName)); } String realFileName = System.currentTimeMillis() + fileName.substring(fileName.indexOf("_") + 1); - String filePath = RuoYiConfig.getDownloadPath() + fileName; + String filePath = CpzIdcConfig.getDownloadPath() + fileName; response.setContentType(MediaType.APPLICATION_OCTET_STREAM_VALUE); FileUtils.setAttachmentResponseHeader(response, realFileName); @@ -78,7 +78,7 @@ try { // 上传文件路径 - String filePath = RuoYiConfig.getUploadPath(); + String filePath = CpzIdcConfig.getUploadPath(); // 上传并返回新文件名称 String fileName = FileUploadUtils.upload(filePath, file); String url = serverConfig.getUrl() + fileName; @@ -104,7 +104,7 @@ try { // 上传文件路径 - String filePath = RuoYiConfig.getUploadPath(); + String filePath = CpzIdcConfig.getUploadPath(); List<String> urls = new ArrayList<String>(); List<String> fileNames = new ArrayList<String>(); List<String> newFileNames = new ArrayList<String>(); @@ -146,7 +146,7 @@ throw new Exception(StringUtils.format("资源文件({})非法,不允许下载。 ", resource)); } // 本地资源路径 - String localPath = RuoYiConfig.getProfile(); + String localPath = CpzIdcConfig.getProfile(); // 数据库资源地址 String downloadPath = localPath + StringUtils.substringAfter(resource, Constants.RESOURCE_PREFIX); // 下载名称 -- Gitblit v1.9.3