refactor(视图): 导出视图明细变更为xlsx格式

This commit is contained in:
wangjiahao 2022-10-08 11:19:31 +08:00
parent 19bed739d1
commit 2f8e8c7afb
2 changed files with 3 additions and 3 deletions

View File

@ -664,7 +664,7 @@ public class PanelGroupService {
}
response.setContentType("application/vnd.ms-excel");
//文件名称
response.setHeader("Content-disposition", "attachment;filename=" + request.getViewName() + ".xls");
response.setHeader("Content-disposition", "attachment;filename=" + request.getViewName() + ".xlsx");
wb.write(outputStream);
outputStream.flush();
outputStream.close();

View File

@ -61,7 +61,7 @@ export default {
type: String,
default: 'details'
}
},
data() {
return {
@ -231,7 +231,7 @@ export default {
const link = document.createElement('a')
link.style.display = 'none'
link.href = URL.createObjectURL(blob)
link.download = excelName + '.xls' //
link.download = excelName + '.xlsx' //
document.body.appendChild(link)
link.click()
document.body.removeChild(link)