|
@@ -14,7 +14,7 @@
|
|
is-check :check-style="{ width: 29 }" @selection-change="tableSelectionChange"
|
|
is-check :check-style="{ width: 29 }" @selection-change="tableSelectionChange"
|
|
>
|
|
>
|
|
<template #action="{ row }">
|
|
<template #action="{ row }">
|
|
- <el-link type="primary" :disabled="!row.rawUrl" @click="rowViewRawPdf(row)">查看电签报表</el-link>
|
|
|
|
|
|
+ <el-link v-loading="rowViewLoading" type="primary" :disabled="!row.rawUrl" @click="rowViewRawPdf(row)">查看电签报表</el-link>
|
|
<el-link type="primary" @click="viewPdf(row)">查看报表</el-link>
|
|
<el-link type="primary" @click="viewPdf(row)">查看报表</el-link>
|
|
<el-link type="primary" :disabled="row.approveStatus === 0" @click="eVisaRowClick(row)">查看电签流程</el-link>
|
|
<el-link type="primary" :disabled="row.approveStatus === 0" @click="eVisaRowClick(row)">查看电签流程</el-link>
|
|
<el-link type="success" @click="editRow(row)">修改</el-link>
|
|
<el-link type="success" @click="editRow(row)">修改</el-link>
|
|
@@ -62,6 +62,7 @@ import periodApi from '~api/debit-pay/material/periods.js'
|
|
import { useAppStore } from '~src/store'
|
|
import { useAppStore } from '~src/store'
|
|
import { formValidate, getArrValue, isNullES } from 'js-fast-way'
|
|
import { formValidate, getArrValue, isNullES } from 'js-fast-way'
|
|
import { toPdfPage } from '~uti/btn-auth'
|
|
import { toPdfPage } from '~uti/btn-auth'
|
|
|
|
+import taskApi from '~api/tasks/hc-data'
|
|
const useAppState = useAppStore()
|
|
const useAppState = useAppStore()
|
|
const contractId = ref(useAppState.getContractId)
|
|
const contractId = ref(useAppState.getContractId)
|
|
const projectId = ref(useAppState.getProjectId)
|
|
const projectId = ref(useAppState.getProjectId)
|
|
@@ -296,9 +297,33 @@ const formModalClose = () => {
|
|
}
|
|
}
|
|
|
|
|
|
const rowViewRawPdf = (row)=>{
|
|
const rowViewRawPdf = (row)=>{
|
|
- toPdfPage(row?.rawUrl)
|
|
|
|
|
|
+ // toPdfPage(row?.rawUrl)
|
|
|
|
+ const { status } = row
|
|
|
|
+ if (status === 1) {
|
|
|
|
+ handleViewPdf(row)
|
|
|
|
+ } else {
|
|
|
|
+ toPdfPage(row?.rawUrl)
|
|
|
|
+ }
|
|
|
|
+}
|
|
|
|
+//查看报表
|
|
|
|
+const rowViewLoading = ref(false)
|
|
|
|
+const handleViewPdf = async (row) => {
|
|
|
|
+ const { id, taskId } = row
|
|
|
|
+ rowViewLoading.value = true
|
|
|
|
+ const { code, msg, data } = await taskApi.taskMeterPdfInfo({
|
|
|
|
+ reportId: id,
|
|
|
|
+ type: 1,
|
|
|
|
+ taskType: 10,
|
|
|
|
+ taskId: taskId,
|
|
|
|
+ })
|
|
|
|
+ rowViewLoading.value = false
|
|
|
|
+ if (code === 200 && !isNullES(data)) {
|
|
|
|
+ window.$message.success('操作成功')
|
|
|
|
+ toPdfPage(data)
|
|
|
|
+ } else {
|
|
|
|
+ window.$message.error(msg ?? '操作失败')
|
|
|
|
+ }
|
|
}
|
|
}
|
|
-
|
|
|
|
//查看电签流程
|
|
//查看电签流程
|
|
const isTaskModal = ref(false)
|
|
const isTaskModal = ref(false)
|
|
const taskDataId = ref('')
|
|
const taskDataId = ref('')
|