vue3前端页面下载excel模版
1.excel上传到public目录下
2.代码中引用excel路径
<el-space direction="horizontal" size="small">
<el-button @click="handleChangePage">刷新列表</el-button>
<el-button type="primary" @click="handleBatchUpload">批量上传</el-button>
<a :href="templateUrl" download="阿里巴巴全链接表_模版.xlsx">
<el-button type="info">下载 Excel 模板</el-button>
</a>
</el-space>
const templateUrl = '/public/阿里巴巴全链接表_模版.xlsx'
原文地址:https://blog.csdn.net/qq_43048011/article/details/140474805
免责声明:本站文章内容转载自网络资源,如本站内容侵犯了原著者的合法权益,可联系本站删除。更多内容请关注自学内容网(zxcms.com)!