Commit 6075e5fe authored by zhuangxinwei's avatar zhuangxinwei

修改bug

parent d75d0914
......@@ -73,11 +73,11 @@ export function delData(dictCode) {
}
// 导出字典数据
export function exportData(query) {
export function exportData(params) {
return request({
url: '/system/dict/data/export/' + query.dictType,
url: '/system/dict/data/export',
method: 'get',
params: query,
params,
responseType: 'blob'
})
}
......@@ -424,13 +424,15 @@ export default {
},
/** 导出按钮操作 */
handleExport() {
const queryParams = this.queryParams
const params = {
dictType: this.queryParams.dictType
}
this.$confirm('是否确认导出所有数据项?', '提示', {
confirmButtonText: '确定',
cancelButtonText: '取消',
type: 'warning'
}).then(function() {
return exportData(queryParams).then(response => {
}).then(() => {
exportData(params).then(response => {
const blob = new Blob([response])
const downloadElement = document.createElement('a')
const href = window.URL.createObjectURL(blob)// 创建下载的链接
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment