|
|
@@ -27,10 +27,8 @@ import lombok.extern.slf4j.Slf4j; |
|
|
|
import org.springframework.beans.factory.annotation.Autowired; |
|
|
|
import org.springframework.stereotype.Service; |
|
|
|
|
|
|
|
import java.io.File; |
|
|
|
import java.io.FileInputStream; |
|
|
|
import java.io.FileNotFoundException; |
|
|
|
import java.io.InputStream; |
|
|
|
import java.io.*; |
|
|
|
import java.net.URLEncoder; |
|
|
|
import java.util.Comparator; |
|
|
|
import java.util.List; |
|
|
|
import java.util.stream.Collectors; |
|
|
@@ -102,6 +100,13 @@ public class ExportReportService { |
|
|
|
|
|
|
|
// 上传到oss |
|
|
|
String ossUrl = this.uploadOss(filePath, filename); |
|
|
|
//对下载地址进行一次URL编码操作 |
|
|
|
try { |
|
|
|
ossUrl = URLEncoder.encode(ossUrl, "utf-8"); |
|
|
|
} catch (UnsupportedEncodingException e) { |
|
|
|
log.info("对下载地址进行编码失败 ossUrl={}",ossUrl); |
|
|
|
e.printStackTrace(); |
|
|
|
} |
|
|
|
|
|
|
|
// 记录 |
|
|
|
this.insertAirDataExport(request, inspection, airDataType, ossUrl); |