Commit 36a0a534 authored by 盖献康's avatar 盖献康

bug(64630) - 文件对话框查看

parent c0e02ef0
...@@ -92,6 +92,23 @@ ...@@ -92,6 +92,23 @@
style="margin: 0 80px 0 0" style="margin: 0 80px 0 0"
@pagination="getContract" @pagination="getContract"
/> />
<!-- 合同文件查看 -->
<el-dialog
title="合同文件"
:visible.sync="openContractDocument"
:before-close="closeContractDocument"
width="50%"
append-to-body
:close-on-click-modal="false"
:close-on-press-escape="false"
>
<iframe
:src="contractDocumentUrl"
frameborder="no"
style="width: 100%; height: 60vh"
scrolling="auto"
/>
</el-dialog>
</div> </div>
</template> </template>
...@@ -104,6 +121,10 @@ export default { ...@@ -104,6 +121,10 @@ export default {
name: 'EntryContract', name: 'EntryContract',
data() { data() {
return { return {
// 控制合同文件对话框
openContractDocument: false,
// 合同文件路径
contractDocumentUrl: null,
// 图片根据不同环境显示路径 // 图片根据不同环境显示路径
baseUrl: process.env.VUE_APP_TEST_API, baseUrl: process.env.VUE_APP_TEST_API,
// 授权合同 // 授权合同
...@@ -130,6 +151,11 @@ export default { ...@@ -130,6 +151,11 @@ export default {
}, 500) }, 500)
}, },
methods: { methods: {
// 合同文件查看对话框关闭
closeContractDocument() {
this.openContractDocument = false
this.contractDocumentUrl = null
},
getEntryContract() { getEntryContract() {
this.queryParams.hospitalId = this.currentHospitalId this.queryParams.hospitalId = this.currentHospitalId
listNoPageHistory(this.queryParams).then(res => { listNoPageHistory(this.queryParams).then(res => {
...@@ -165,9 +191,8 @@ export default { ...@@ -165,9 +191,8 @@ export default {
}) })
}, },
check(row) { check(row) {
console.log('pdf', row.contract) this.openContractDocument = true
console.log('pdf2', this.baseUrl) this.contractDocumentUrl = this.baseUrl + row.contract
window.open(this.baseUrl + row.contract)
}, },
downloadPdf(row) { downloadPdf(row) {
this.$download.resource(row.contract) this.$download.resource(row.contract)
......
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