오류 수정

This commit is contained in:
leejunho 2025-01-16 18:27:14 +09:00
parent 8c2871a300
commit 807b635474
2 changed files with 7 additions and 2 deletions

View File

@ -433,7 +433,7 @@ public class EgovFileDownloadController {
String s_path = (String) commandMap.get("path"); String s_path = (String) commandMap.get("path");
String s_file = (String) commandMap.get("file"); String s_file = (String) commandMap.get("file");
File uFile = new File(pdfFilePath + "/resultFile/" + s_path, s_file); File uFile = new File(pdfFilePath + "/resultFile/", s_file);
String mimetype = "application/x-msdownload"; String mimetype = "application/x-msdownload";

View File

@ -1,5 +1,6 @@
package kcc.com.pdf.service.impl; package kcc.com.pdf.service.impl;
import java.io.UnsupportedEncodingException;
import java.net.URLEncoder; import java.net.URLEncoder;
import java.nio.charset.StandardCharsets; import java.nio.charset.StandardCharsets;
import java.time.LocalDateTime; import java.time.LocalDateTime;
@ -210,7 +211,11 @@ public class PdfServiceImpl extends EgovAbstractServiceImpl implements PdfServic
options.getOption().add(option); options.getOption().add(option);
mergeTask.getOptions().add(options); mergeTask.getOptions().add(options);
fileNames.append("%2C%20%3C%2Fbr%3E" + t.getFileName()); try {
fileNames.append("%2C%20%3C%2Fbr%3E" + URLEncoder.encode(t.getFileName(), StandardCharsets.UTF_8.toString()));
} catch (UnsupportedEncodingException e) {
e.printStackTrace();
}
} }
); );