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
<template>
<div class="h-full">
<div class="p-3 text-16 text-black text-center shrink-0 top-bar">
<!-- <span class="back-bt">
<span @click="onBack">
<doc-icon type="doc-left" />
</span>
</span> -->
<span>慢病筛查记录</span>
</div>
<div class='card' v-for='item in list' :key="item.id">
<div class="p-4">
<div class='text-16 font-semibold mb-2 title'>{{ item.residentName }}</div>
<div class="mb-2">
<span class="label">证件号码</span>
<span>{{ $idCardHide(item.idCard) }}</span>
</div>
<div class="mb-2">
<span class="label">筛查日期</span>
<span>{{ item.screenDate }}</span>
</div>
<div class="mb-2">
<span class="label">筛查机构</span>
<span>{{ item.screenUnitName }}</span>
</div>
<div class="bt-box flex pt-2 justify-end">
<van-button type="primary" size="small"
@click="toDetail(item)">详 情</van-button>
</div>
</div>
<div class="divide"></div>
</div>
</div>
</template>
<script>
import { showNotify } from 'vant'
import { querScreenList } from '@/api/resident/screening.js'
export default {
data() {
return {
list: []
}
},
computed: {
routeQuery() {
return this.$route.query
},
idCard() {
return this.routeQuery.idCard
}
},
created() {
if (!this.idCard) {
showNotify({ type: 'warning', message: '未获取到用户信息', duration: 0 })
return
}
this.init()
},
methods: {
init() {
querScreenList({ idCard: this.idCard }).then(res => {
this.list = res.data || []
})
},
toDetail(record) {
if (!record) return
const path = `/resident/screening/first/detail/${record.id}`
this.$router.push({ path })
}
}
}
</script>
<style lang="less" scoped>
@import url('../../../utils/common.less');
.card {
.label {
display: inline-block;
min-width: 5em;
color: #8C8C8C;
}
.bt-box {
border-top: 1px solid var(--van-border-color);
}
.divide {
border-top: 6px solid #f5f5f5;
}
&:last-child {
.divide { display: none; }
}
}
</style>