更新记录
1.0.0(2025-10-18)
插件当前版本为1.0.0 已有功能支持 导出日常的数据,系统规定第一行为表头。需要准备好对应的表头和表体数据
平台兼容性
uni-app(4.76)
Vue2 |
Vue3 |
Chrome |
Safari |
app-vue |
app-nvue |
Android |
iOS |
鸿蒙 |
× |
× |
× |
- |
- |
- |
× |
× |
× |
微信小程序 |
支付宝小程序 |
抖音小程序 |
百度小程序 |
快手小程序 |
京东小程序 |
鸿蒙元服务 |
QQ小程序 |
飞书小程序 |
快应用-华为 |
快应用-联盟 |
× |
× |
- |
- |
- |
- |
- |
- |
- |
- |
- |
uni-app x(4.76)
Chrome |
Safari |
Android |
Android插件版本 |
iOS |
鸿蒙 |
微信小程序 |
× |
× |
5.0 |
1.0.0 |
× |
× |
× |
juyiju-excelExport
开发文档
插件当前版本为1.0.0 已有功能支持 导出日常的数据,系统规定第一行为表头。需要准备好对应的表头和表体数据
使用方法 如下,成功和错误都有返回JSONObject,下个版本增加excel导入功能。其他方法陆续开发完善中。
import { syncExport,asyncExport } from '@/uni_modules/juyiju-excelExport';
```javascript
参数设置:
let listColumnWdith=["30","30","30"]; //每个单元格宽度设置
let listHead=["序号","标题","内容"];//表头(即第一行)
let listBody=[["1","测试","测试内容"],["2","小张","小小张"]]; //表体内容(即第二行开始),数组结构
let folderName="test/";//文件夹路径
let fileName="test.xls";//文件名称
```javascript
同步方法:
const sync_export=syncExport(listColumnWdith,listHead,listBody,folderName,fileName);
console.log("sync_export:"+JSON.stringify(sync_export));
```javascript
异步方法
asyncExport(listColumnWdith,listHead,listBody,folderName,fileName,(res) => {
console.log("res:"+JSON.stringify(res))
})