|
@@ -24,7 +24,7 @@
|
|
|
<HcDrawer v-model="isCarrySpotChecksDrawer" ui="hc-carry-spot-checks-target" to-id="carry-spot-checks-layout-target1" flex @close="onCarrySpotChecksDrawerClose">
|
|
|
<div class="hc-carry-spot-checks-pdf">
|
|
|
<div v-loading="pdfLoading" class="h-full">
|
|
|
- <HcPdf v-if="isshowPdf" :src="pdfUrl" />
|
|
|
+ <HcPdf v-if="isshowPdf" :src="pdfUrl" @rendered="getPdfTime" />
|
|
|
</div>
|
|
|
<el-tooltip content="展开/收起 右侧目录" placement="top" :disabled="!isBubble">
|
|
|
<div class="hc-csc-pdf-btn" @click="onCarryDataShow">
|
|
@@ -388,6 +388,7 @@ const changePdf = (row)=>{
|
|
|
isshowPdf.value = true
|
|
|
}, 100)
|
|
|
// pdfUrl.value = row['pdfFileUrl'] || ''
|
|
|
+ pdfShowTime.value = 0
|
|
|
|
|
|
let rawUrl = row['pdfFileUrl'] || ''
|
|
|
|
|
@@ -402,6 +403,11 @@ const changePdf = (row)=>{
|
|
|
|
|
|
|
|
|
}
|
|
|
+const pdfShowTime = ref(0)
|
|
|
+const getPdfTime = (val)=>{
|
|
|
+ pdfShowTime.value = val
|
|
|
+}
|
|
|
+
|
|
|
// 监控pdfUrl和shouldCarryOutSpotChecks的变化
|
|
|
watch([pdfUrl, isCarrySpotChecksDrawer], ([newPdfUrl, newShouldCarryOutSpotChecks]) => {
|
|
|
if (newPdfUrl && newPdfUrl.length > 0 && newShouldCarryOutSpotChecks) {
|
|
@@ -410,7 +416,8 @@ watch([pdfUrl, isCarrySpotChecksDrawer], ([newPdfUrl, newShouldCarryOutSpotCheck
|
|
|
if (pdfUrl.value === newPdfUrl && isCarrySpotChecksDrawer.value) {
|
|
|
serReviewFile()
|
|
|
}
|
|
|
- }, 30000)
|
|
|
+
|
|
|
+ }, pdfShowTime.value ? pdfShowTime.value + 30000 : 30000)
|
|
|
}
|
|
|
}, { deep: true })
|
|
|
const opid = ref('')
|
|
@@ -623,6 +630,7 @@ const onCarrySpotChecksDrawerClose = () => {
|
|
|
ishowFile.value = false
|
|
|
checkmetaFileId.value = ''
|
|
|
tabTypeKey.value = 'tab1'
|
|
|
+ pdfShowTime.value = 0
|
|
|
getTableData()
|
|
|
}
|
|
|
|