|
|
@ -547,7 +547,8 @@ export default { |
|
|
|
} |
|
|
|
} |
|
|
|
await load(); |
|
|
|
} else if (item.path === "export") { |
|
|
|
} |
|
|
|
else if (item.path === "export") { |
|
|
|
if (item.meta.pattern === "paged") { |
|
|
|
const url = config.edit.exportUrl; |
|
|
|
const method = config.edit.exportMethod; |
|
|
@ -573,7 +574,35 @@ export default { |
|
|
|
} else { |
|
|
|
console.log(item); |
|
|
|
} |
|
|
|
} else if (item.path === "import") { |
|
|
|
} |
|
|
|
else if (item.path === "exportdiff") { |
|
|
|
if (item.meta.pattern === "paged") { |
|
|
|
const url = config.edit.exportdiffUrl; |
|
|
|
const method = config.edit.exportdiffMethod; |
|
|
|
const postData = buildQuery(); |
|
|
|
await onClick(async () => { |
|
|
|
const response = await request(url, postData, { method }); |
|
|
|
if (!response.errors) { |
|
|
|
window.open(getUrl(`settleaccount/getblobfile/download/${response.data}`)); |
|
|
|
} |
|
|
|
}, "确认导出?"); |
|
|
|
} else if (item.meta.pattern === "file") { |
|
|
|
window.open(getUrl(`settleaccount/getblobfile/download/${rows[0]["downFileName"]}`)); |
|
|
|
} else if ((item.meta.pattern = "row")) { |
|
|
|
const url = config.edit.exportUrl; |
|
|
|
const method = config.edit.exportMethod ?? "POST"; |
|
|
|
const postData = { |
|
|
|
[item.meta.key]: rows[0][item.meta.key], |
|
|
|
}; |
|
|
|
const response = await request(url, postData, { method }); |
|
|
|
if (!response.errors) { |
|
|
|
window.open(getUrl(`settleaccount/getblobfile/download/${response.data}`)); |
|
|
|
} |
|
|
|
} else { |
|
|
|
console.log(item); |
|
|
|
} |
|
|
|
} |
|
|
|
else if (item.path === "import") { |
|
|
|
//import
|
|
|
|
try { |
|
|
|
importModel.value = Object.assign({}, defaultImportModel); |
|
|
|