|
|
@@ -680,18 +680,19 @@
|
|
|
id: row.id,
|
|
|
}).then((res) => {
|
|
|
if (res.state) {
|
|
|
- this.fileUrl = res.value || ''
|
|
|
+ // this.fileUrl = res.value || ''
|
|
|
+ this.handleViewScan(res.value || '')
|
|
|
} else {
|
|
|
this.$message.error('获取文件URL失败')
|
|
|
}
|
|
|
})
|
|
|
// this.handleTemplateChange()
|
|
|
- this.documentDialogVisible = true
|
|
|
- getCostProjectDocumentFile({
|
|
|
- id: row.id,
|
|
|
- }).then((res) => {
|
|
|
- this.costDocumentTemplateFiles = res.value || []
|
|
|
- })
|
|
|
+ // this.documentDialogVisible = true
|
|
|
+ // getCostProjectDocumentFile({
|
|
|
+ // id: row.id,
|
|
|
+ // }).then((res) => {
|
|
|
+ // this.costDocumentTemplateFiles = res.value || []
|
|
|
+ // })
|
|
|
},
|
|
|
handleDocumentTypeClick(data) {
|
|
|
this.activeDocumentTypeId = data.id
|
|
|
@@ -1140,9 +1141,14 @@
|
|
|
this.$message.error('暂无文件!')
|
|
|
return
|
|
|
}
|
|
|
- const encodedUrl = encodeURIComponent(
|
|
|
- Base64.encode(window.context.form + fileUrl)
|
|
|
- )
|
|
|
+ let _fileUrl = ''
|
|
|
+ if (fileUrl.startsWith('http')) {
|
|
|
+ _fileUrl = fileUrl
|
|
|
+ } else {
|
|
|
+ fileUrl = window.context.form + fileUrl
|
|
|
+ }
|
|
|
+ // 对文件URL进行Base64编码
|
|
|
+ const encodedUrl = encodeURIComponent(Base64.encode(_fileUrl))
|
|
|
window.open(`${host}:8012/onlinePreview?url=${encodedUrl}`)
|
|
|
},
|
|
|
handleUploadClick(row) {
|