Commit 31c5a5cb authored by 张伯涛's avatar 张伯涛

预览

parent 52885140
...@@ -3,5 +3,5 @@ ENV = 'test' ...@@ -3,5 +3,5 @@ ENV = 'test'
NODE_ENV= 'production' NODE_ENV= 'production'
# 测试环境 # 测试环境
# base api # base api
VUE_APP_BASE_API = 'http://10.19.100.58:8090' VUE_APP_BASE_API = 'http://117.122.212.101:8090'
...@@ -2014,17 +2014,22 @@ export default { ...@@ -2014,17 +2014,22 @@ export default {
} }
}, },
filePreview(row) { filePreview(row) {
console.log('数据', row) const fileType = row.FILENAME.split('.')[row.FILENAME.split('.').length - 1]
this.filePreviewDialog = true console.log('数据', row, fileType)
this.$axios.get(this.HTTPApi + '/contractjxx/contract-fjxx/preview/' + row.BUSINESSID).then(res => { if (fileType === 'pdf') {
if (!res.errno) { this.filePreviewDialog = true
this.fileUrl = res.data.data this.$axios.get(this.HTTPApi + '/contractjxx/contract-fjxx/preview/' + row.BUSINESSID).then(res => {
} if (!res.errno) {
console.log('数据aaaa', this.fileUrl) this.fileUrl = res.data.data
}) }
.catch(function(error) { console.log('数据aaaa', this.fileUrl)
console.log(error)
}) })
.catch(function(error) {
console.log(error)
})
} else {
this.$message.warning('只有附件类型为PDF的附件可以预览!')
}
}, },
uploadF2(file) { uploadF2(file) {
console.log(file, 'file') console.log(file, 'file')
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment