Commit bae691d3 authored by chenzhao's avatar chenzhao

ziliaoxiazai youhua

parent d927cd82
......@@ -579,13 +579,8 @@ public class CommonServiceImpl {
System.out.println("模版文件所在目录是: " + templateDir);
Path tempDir = createUniqueDirectory(ziLiaoDir, returnDto.getSurveyInformation().getOwnersName());
boolean directoryExists = Files.exists(tempDir);
if (directoryExists){
}else {
}
Path tempDir = createUniqueDirectory(ziLiaoDir, returnDto.getSurveyInformation().getOwnersName());
String wenjianjia = tempDir.toString().replace("\\","/");
try {
Files.createDirectories(tempDir); // 创建临时目录
System.out.println("Temporary directory created at: " + tempDir);
......@@ -593,10 +588,11 @@ public class CommonServiceImpl {
e.printStackTrace();
return;
}
String templatePath = "templates/informationTemp.xlsx";
//String templatePath = "F:\\work\\amos-boot-zx-biz\\amos-boot-system-jxiop\\amos-boot-module-hygf-biz\\src\\main\\resources\\templates\\informationTemp.xlsx";
// String outputPath = "F:\\work\\amos-boot-zx-biz\\amos-boot-system-jxiop\\amos-boot-module-hygf-biz\\src\\main\\resources\\templates\\temp\\"+returnDto.getSurveyInformation().getOwnersName()+".xlsx";
String outputPath ="批量资料/"+ returnDto.getSurveyInformation().getOwnersName()+"/"+returnDto.getSurveyInformation().getOwnersName()+".xlsx";
String outputPath =wenjianjia+"/"+returnDto.getSurveyInformation().getOwnersName()+".xlsx";
Workbook workbook = null;
try ( InputStream fis = new ClassPathResource(templatePath).getInputStream()){
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment