ren
This commit is contained in:
@@ -90,7 +90,7 @@
|
||||
|
||||
<el-table-column label="姓名/工号" min-width="150" align="center">
|
||||
<template #default="scope">
|
||||
<TeacherNameNo :name="scope.row.teacherName" :no="scope.row.teacherNo" />
|
||||
<TeacherNameNo :name="scope.row.realName" :no="scope.row.teacherNo" />
|
||||
</template>
|
||||
</el-table-column>
|
||||
|
||||
@@ -157,8 +157,15 @@
|
||||
@size-change="sizeChangeHandle"
|
||||
/>
|
||||
|
||||
<!-- 材料预览:图片直接显示,PDF 在组件内部 dialog 中显示 -->
|
||||
<auth-img
|
||||
v-for="src in imgUrl"
|
||||
:key="src.title"
|
||||
:authSrc="src.url"
|
||||
dialog-title="综合表彰材料"
|
||||
/>
|
||||
|
||||
<!-- 子组件 -->
|
||||
<ShowHonorEdvince ref="showHonorEdvinceRef" />
|
||||
<ProfessionalBackResaon ref="backReasonRef" @refreshData="handleFilter" />
|
||||
<DataForm ref="dataFormRef" @refreshData="handleFilter" />
|
||||
</div>
|
||||
@@ -166,7 +173,7 @@
|
||||
</template>
|
||||
|
||||
<script setup lang="ts">
|
||||
import { ref, reactive, computed, onMounted } from 'vue'
|
||||
import { ref, reactive, computed, onMounted, nextTick } from 'vue'
|
||||
import { storeToRefs } from 'pinia'
|
||||
import { useUserInfo } from '/@/stores/userInfo'
|
||||
import { BasicTableProps, useTable } from '/@/hooks/table'
|
||||
@@ -181,9 +188,9 @@ import {
|
||||
import { defineAsyncComponent } from 'vue'
|
||||
const TeacherNameNo = defineAsyncComponent(() => import('/@/components/TeacherNameNo/index.vue'))
|
||||
const AuditState = defineAsyncComponent(() => import('/@/components/AuditState/index.vue'))
|
||||
const ShowHonorEdvince = defineAsyncComponent(() => import('./showHonorEdvince.vue'))
|
||||
const ProfessionalBackResaon = defineAsyncComponent(() => import('/@/views/professional/common/professional-back-resaon.vue'))
|
||||
const DataForm = defineAsyncComponent(() => import('./form.vue'))
|
||||
const authImg = defineAsyncComponent(() => import('/@/components/tools/auth-img.vue'))
|
||||
|
||||
// 使用 Pinia store
|
||||
const userInfoStore = useUserInfo()
|
||||
@@ -216,7 +223,6 @@ const auditStateOptions: StateOption[] = [
|
||||
// 表格引用
|
||||
const tableRef = ref()
|
||||
const searchFormRef = ref()
|
||||
const showHonorEdvinceRef = ref()
|
||||
const backReasonRef = ref()
|
||||
const dataFormRef = ref()
|
||||
const showSearch = ref(true)
|
||||
@@ -228,6 +234,9 @@ const search = reactive({
|
||||
teacherName: ''
|
||||
})
|
||||
|
||||
// 材料预览
|
||||
const imgUrl = ref<Array<{ title: string; url: string }>>([])
|
||||
|
||||
// 导出加载状态
|
||||
const exportLoading = ref(false)
|
||||
|
||||
@@ -247,9 +256,18 @@ const state: BasicTableProps = reactive<BasicTableProps>({
|
||||
|
||||
const { getDataList, currentChangeHandle, sizeChangeHandle, tableStyle } = useTable(state)
|
||||
|
||||
// 查看证明材料
|
||||
// 查看证明材料:构造预览列表,交给 auth-img 处理
|
||||
const showEdvince = (row: any) => {
|
||||
showHonorEdvinceRef.value?.init(row)
|
||||
imgUrl.value = []
|
||||
nextTick(() => {
|
||||
const list = row.attachment ? [row.attachment] : []
|
||||
list.forEach(v => {
|
||||
imgUrl.value.push({
|
||||
title: '',
|
||||
url: v
|
||||
})
|
||||
})
|
||||
})
|
||||
}
|
||||
|
||||
// 审核状态变更
|
||||
|
||||
Reference in New Issue
Block a user