From 78a3c898908bbb8827d1c2aa6299f92ff03f5847 Mon Sep 17 00:00:00 2001
From: 吴羡 <16976746+Xian-TT3@user.noreply.gitee.com>
Date: 星期三, 21 十月 2026 15:06:09 +0800
Subject: [PATCH] Merge remote-tracking branch 'origin/master'
---
src/views/CNAS/systemManagement/documentControl/components/FileChangeRequest.vue | 14 +++++++++++---
1 files changed, 11 insertions(+), 3 deletions(-)
diff --git a/src/views/CNAS/systemManagement/documentControl/components/FileChangeRequest.vue b/src/views/CNAS/systemManagement/documentControl/components/FileChangeRequest.vue
index fcf241d..d65c19d 100644
--- a/src/views/CNAS/systemManagement/documentControl/components/FileChangeRequest.vue
+++ b/src/views/CNAS/systemManagement/documentControl/components/FileChangeRequest.vue
@@ -184,7 +184,7 @@
<div class="search_thing" style="width: 100%;">
<div class="search_label">鐩稿叧闄勪欢锛�</div>
<div class="search_input"><el-upload v-if="addDialogVisible" :auto-upload="false" :multiple="false"
- :on-change="handleChangeUpload" accept='.pdf' action="#" style="margin: 8px 0 0px 50px;">
+ :on-change="handleChangeUpload" accept='.pdf,.doc,.docx,.xls,.xlsx,.ppt,.pptx,.wps,.et,.dps,.txt,.jpg,.jpeg,.png' action="#" style="margin: 8px 0 0px 50px;">
<el-button size="small" type="primary">涓婁紶闄勪欢</el-button>
</el-upload></div>
</div>
@@ -536,15 +536,23 @@
this.getCurrentFile(alterBeforeCode)
this.addDialogVisible = true
this.diaLoading = true
- checkManageDocumentAlterPdf({ id: row.id }).then(res => {
+ checkManageDocumentAlterPdf({ id: row.id }).then(async res => {
//
this.diaLoading = false
- const blob = new Blob([res]);
+ // 鍚庣杞� PDF 澶辫触鏃朵細杩斿洖 JSON 閿欒锛宐lob 閲屽氨涓嶆槸 PDF
+ if (res.type && res.type.includes('json')) {
+ const data = JSON.parse(await res.text())
+ this.$message.error(data.msg || '闄勪欢杞崲棰勮澶辫触')
+ this.addDialogVisible = false
+ return
+ }
+ const blob = new Blob([res], { type: 'application/pdf' });
const file = new File([blob], row.name, { type: 'application/pdf' })
this.$refs.UpPdfStamp.lookFile(file)
this.currentInfo = row
}).catch(err => {
this.diaLoading = false
+ this.addDialogVisible = false
console.log(err)
})
},
--
Gitblit v1.9.3