Commit 1b1a0670 by 杨林龙

开发试驾数据 设置自动关闭写出流属性

1 parent d1683b69
...@@ -82,7 +82,7 @@ public class EffectiveTestDriveReportController { ...@@ -82,7 +82,7 @@ public class EffectiveTestDriveReportController {
// 封装数据 // 封装数据
List<EffectiveTestDriveReportExcel> testDriveReportExcels = effectiveTestDriveReportService.exportEffectiveTestDriveReport(reportRequest, testDrivePageList); List<EffectiveTestDriveReportExcel> testDriveReportExcels = effectiveTestDriveReportService.exportEffectiveTestDriveReport(reportRequest, testDrivePageList);
response.setHeader("Content-disposition", "attachment;filename*=utf-8''" + fileName + ".xlsx"); response.setHeader("Content-disposition", "attachment;filename*=utf-8''" + fileName + ".xlsx");
EasyExcel.write(response.getOutputStream(), EffectiveTestDriveReportExcel.class).sheet("有效试驾次数统计(按日)表").doWrite(testDriveReportExcels); EasyExcel.write(response.getOutputStream(), EffectiveTestDriveReportExcel.class).autoCloseStream(true).sheet("有效试驾次数统计(按日)表").doWrite(testDriveReportExcels);
} }
@GetMapping(value = "/getYearWithData") @GetMapping(value = "/getYearWithData")
......
Markdown is supported
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!