examination.vue
3.47 KB
1
2
3
4
5
6
7
8
9
10
11
12
13
14
15
16
17
18
19
20
21
22
23
24
25
26
27
28
29
30
31
32
33
34
35
36
37
38
39
40
41
42
43
44
45
46
47
48
49
50
51
52
53
54
55
56
57
58
59
60
61
62
63
64
65
66
67
68
69
70
71
72
73
74
75
76
77
78
79
80
81
82
83
84
85
86
87
88
89
90
91
92
93
94
95
96
97
98
99
100
101
102
103
104
105
106
107
108
109
110
111
112
<template>
<div v-loading="loadingContent" class="app-container">
<el-card class="box-card">
<div>
<el-button :disabled="form.isPoints==0||formInfo.auditStatus==1" class="btn" icon="plus" type="primary" @click="handelExamination">考点申请</el-button>
</div>
<br>
<br>
<el-table v-loading="loading" :data="listInfo" border>
<el-table-column align="center" label="序号" type="index" width="55" />
<el-table-column
align="center" label="审核协会" min-width="160px" prop="auditDeptName" show-overflow-tooltip
/>
<el-table-column align="center" label="审核日期" min-width="100" prop="auditTime">
<template #default="{row}">
<span>{{ parseTime(row.auditTime, '{y}-{m}-{d}') }}</span>
</template>
</el-table-column>
<el-table-column align="center" label="审核状态" min-width="110">
<template #default="{row}">
<div v-if="row.auditResult==1" class="text-success">审核通过</div>
<div v-else-if="row.auditResult==0" class="text-danger"> 审核拒绝</div>
<div v-else>待审核</div>
</template>
</el-table-column>
<el-table-column align="center" label="理由" min-width="100" prop="auditMsg">
<template #default="{row}">
<div>{{ row.auditMsg ? row.auditMsg : '/' }}</div>
</template>
</el-table-column>
</el-table>
<kaoDianShenQingXuZhi ref="kaoDianShenQingXuZhiRef" @handel-next="handelNext" />
<cangGuanImage ref="cangGuanImageRef" @handel-next="handelNext2" />
<applyNow ref="applyNowRef" @handel-submit="handelSubmit" />
</el-card>
</div>
</template>
<script setup >
import { getCurrentInstance, ref, onMounted, computed } from 'vue'
// import { getMyRecent } from '@/api/system/config'
import applyNow from '@/views/system/user/profile/components/applyNow'
import useUserStore from '@/store/modules/user'
import kaoDianShenQingXuZhi from '@/views/groupMember/components/kaoDianShenQingXuZhi.vue'
import cangGuanImage from '@/views/groupMember/components/cangGuanImage.vue'
import { getMyOwnMemberInfo } from '@/api/system/userInfo'
import { useRoute } from 'vue-router'
import { getMyRecent } from '@/api/system/userInfo'
const memId = computed(() => useUserStore().memId)
const { proxy } = getCurrentInstance()
const loading = ref(false)
const loadingContent = ref(false)
const listInfo = ref([])
const form = ref({})
const formInfo = ref({})
const route = useRoute()
onMounted(() => {
if (route.query.type == 1) {
handelExamination()
}
getMyCertStageFN()
initData()
})
async function getMyCertStageFN() {
loading.value = true
const res = await getMyRecent()
loading.value = false
formInfo.value = res.data ?? {}
if (res.data && res.data.auditLogs) listInfo.value = JSON.parse(res.data.auditLogs)
}
async function initData() {
loadingContent.value = true
const res = await getMyOwnMemberInfo()
form.value = res.data.memberInfo ?? {}
loadingContent.value = false
}
function handelExamination() {
proxy.$refs['kaoDianShenQingXuZhiRef'].open()
}
function handelNext() {
// proxy.$refs['applyNowRef'].open(memId.value)
proxy.$refs['cangGuanImageRef'].open()
}
function handelNext2(photos) {
proxy.$refs['applyNowRef'].open(memId.value, photos)
}
function handelSubmit() {
initData()
getMyCertStageFN()
}
</script>
<style lang="scss" scoped>
.box-card{
width: 1000px;
margin: 0 auto;
}
</style>