no message

Former-commit-id: 790cbb22968ec5539df092e91148e7cc75baf8c1
Former-commit-id: b86992bc97242244f343f0311cae6400adf24641
Former-commit-id: 7d67b7feff3025551a4881da6e75fa11b7ab2fd4
This commit is contained in:
李杨
2018-02-11 22:38:55 +08:00
parent 5bcc00dc8a
commit 8658217baa
3 changed files with 9 additions and 10 deletions

View File

@@ -47,8 +47,8 @@ export default {
columns: this.table.columns,
data: this.table.data
})
.then(data => {
this.$log('exportCsv', data)
.then(() => {
this.$message('导出CSV成功')
})
},
exportExcel () {
@@ -56,8 +56,8 @@ export default {
columns: this.table.columns,
data: this.table.data
})
.then(data => {
this.$log('exportExcel', data)
.then(() => {
this.$message('导出表格成功')
})
}
}

View File

@@ -22,7 +22,7 @@ export default {
// 下载数据
ExportCsv.download(_params.title, data)
// 完成
resolve(data)
resolve()
})
},
// 导出 Excel
@@ -42,10 +42,7 @@ export default {
// 导出 Excel
Excel.export_json_to_excel(header, data, _params.title)
// 完成
resolve({
header,
data
})
resolve()
})
}
}

View File

@@ -15,7 +15,7 @@ Vue.use(pluginExport)
## Vue.$export.csv()
此方法将数据以 `CSV` 格式导出,并且返回一个 `Promise` ,可以使用 `then` 回调
此方法将数据以 `CSV` 格式导出,并且返回一个 `Promise` 对象
使用
@@ -71,6 +71,8 @@ this.$export.csv({
## Vue.$export.excel()
此方法将数据以 `xlsx` 格式导出,并且返回一个 `Promise` 对象
使用
```