mirror of
https://github.com/PanJiaChen/vue-element-admin.git
synced 2025-08-12 22:29:59 +08:00
Fixed error with pdf and binary data for reports
This commit is contained in:
parent
9c6b7dd307
commit
3ed5b6637f
@ -497,11 +497,11 @@ const processControl = {
|
|||||||
href: undefined,
|
href: undefined,
|
||||||
download: undefined
|
download: undefined
|
||||||
}
|
}
|
||||||
if (runProcessResponse.isReport || processDefinition.isReport) {
|
if ((runProcessResponse.isReport || processDefinition.isReport) && output.outputStream) {
|
||||||
const blob = new Blob(
|
const reportObject = Object.values(output.outputStream)
|
||||||
[output.outputStream],
|
const blob = new Blob([Uint8Array.from(reportObject)], {
|
||||||
{ type: output.mimeType }
|
type: output.mimeType
|
||||||
)
|
})
|
||||||
link = document.createElement('a')
|
link = document.createElement('a')
|
||||||
link.href = window.URL.createObjectURL(blob)
|
link.href = window.URL.createObjectURL(blob)
|
||||||
link.download = output.fileName
|
link.download = output.fileName
|
||||||
|
Loading…
x
Reference in New Issue
Block a user