From c9cad1e366b033b8fc664945df200a3289adc166 Mon Sep 17 00:00:00 2001 From: wzy-warehouse <18135009705@163.com> Date: Sun, 28 Jun 2026 16:44:43 +0800 Subject: [PATCH] =?UTF-8?q?=E4=BF=AE=E5=A4=8D=E5=9B=BE=E7=89=87=E6=98=BE?= =?UTF-8?q?=E7=A4=BA?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../com/gis/xian/service/impl/IReportOutputServiceImpl.java | 6 +++++- 1 file changed, 5 insertions(+), 1 deletion(-) diff --git a/src/main/java/com/gis/xian/service/impl/IReportOutputServiceImpl.java b/src/main/java/com/gis/xian/service/impl/IReportOutputServiceImpl.java index 42b018a..318098b 100644 --- a/src/main/java/com/gis/xian/service/impl/IReportOutputServiceImpl.java +++ b/src/main/java/com/gis/xian/service/impl/IReportOutputServiceImpl.java @@ -251,7 +251,11 @@ public class IReportOutputServiceImpl implements ReportOutputService { return files.stream() .filter(f -> expectedName.equals(f.getFileName())) .findFirst() - .map(f -> (reportProperties.getFiles().getServerUrl() + "/" + f.getFilePath()).replace("\\", "/").replace("//", "/")) + .map(f -> { + String server = reportProperties.getFiles().getServerUrl().replaceAll("/+$", ""); + String path = f.getFilePath().replace("\\", "/").replaceAll("^/+", ""); + return server + "/" + path; + }) .orElse(""); }