vue-element-admin icon indicating copy to clipboard operation
vue-element-admin copied to clipboard

使用导出EXCEL功能报错

Open ayamzh opened this issue 2 years ago • 2 comments

Bug report(问题描述)

使用导出excel功能时报错 代码参考文档的 import('@/vendor/Export2Excel').then(excel => { excel.export_json_to_excel({ header: tHeader, //表头 必填 data, //具体数据 必填 filename: 'excel-list', //非必填 autoWidth: true, //非必填 bookType: 'xlsx' //非必填 }) })

Steps to reproduce(问题复现步骤)

Screenshot or Gif(截图或动态图)

image image image

Link to minimal reproduction(最小可在线还原demo)

Other relevant information(格外信息)

  • Your OS:
  • Node.js version:
  • vue-element-admin version:

ayamzh avatar Aug 22 '23 07:08 ayamzh

我也一样

chengleigit avatar Nov 28 '23 07:11 chengleigit

image

import XLSX from 'xlsx' 改为 import * as XLSX from 'xlsx' 即可

Barry-Flynn avatar Mar 14 '24 15:03 Barry-Flynn