|
@@ -184,18 +184,20 @@ const ElTreeMenuClick = async ({ key, node, data, keys }) => {
|
|
|
}
|
|
|
//预览pdf
|
|
|
const viewPdf = async (id) => {
|
|
|
- window.$message?.info('预览案卷需要合并pdf,需要一点时间')
|
|
|
+ const message = window.$message?.info({
|
|
|
+ message: '预览案卷需要合并pdf,需要一点时间',
|
|
|
+ duration: 0, // 设置为0表示不自动关闭
|
|
|
+ })
|
|
|
const { error, code, data, msg } = await tuningApi.printArchive({
|
|
|
id: id,
|
|
|
})
|
|
|
+ message?.close() // 接口完成后手动关闭提示
|
|
|
if (!error && code === 200) {
|
|
|
if (data) {
|
|
|
toPdfPage(data)
|
|
|
- //window.open(data, '_blank')
|
|
|
} else {
|
|
|
window.$message?.warning('文件不存在')
|
|
|
}
|
|
|
-
|
|
|
} else {
|
|
|
window.$message?.warning(msg)
|
|
|
}
|