|
|
@@ -22,8 +22,7 @@ public class EasyExcelUtil {
|
|
|
public String getExcel(Map<String, Object> params, List<?> list,
|
|
|
String template, String wordName) {
|
|
|
String filePath = FileUploadUtils.getAbsoluteFileEncoding(wordName);
|
|
|
- try (InputStream is = Thread.currentThread().getContextClassLoader()
|
|
|
- .getResourceAsStream(template);
|
|
|
+ try (InputStream is = new FileInputStream(template);
|
|
|
OutputStream os = new FileOutputStream(filePath)) {
|
|
|
WriteSheet writeSheet = EasyExcel.writerSheet().build();
|
|
|
ExcelWriter excelWriter = EasyExcel.write(os).withTemplate(is)
|