特殊人群

This commit is contained in:
liuye
2022-08-09 11:00:35 +08:00
parent 0d1999e553
commit 8fd4e899ee
4 changed files with 729 additions and 282 deletions

View File

@@ -1,25 +1,15 @@
<template>
<div class="AppSpecialGroups">
<div class="title">特殊人群总计 : 60</div>
<div class="item" @click="toList">
<div class="title">特殊人群总计 : {{ total }}</div>
<div class="item" @click="toList(item.label)" v-for="(item, index) in statisticsList" :key="index">
<div class="left">
<img src="./img/user-icon-mini.png" alt="">
<span>残疾人残疾人残疾人残疾人残疾人残疾人残疾人残疾人残疾人残疾人</span>
<span>{{ item.label }}</span>
</div>
<div class="right">
12<img src="./img/down-icon-666.png" alt="">
{{ item.value }}<img src="./img/down-icon-666.png" alt="">
</div>
</div>
<div class="item">
<div class="left">
<img src="./img/user-icon-mini.png" alt="">
<span>残疾人</span>
</div>
<div class="right">
12<img src="./img/down-icon-666.png" alt="">
</div>
</div>
</div>
</template>
@@ -29,14 +19,34 @@ export default {
appName: "特殊人群",
data() {
return {
statisticsList: [],
total: 0
}
},
methods: {
toList() {
uni.navigateTo({ url: './List'})
getStatistic() {
this.statisticsList = []
this.total = 0
this.$http.post(`/app/appspecialadjustment/statistic?type=0&range=0`).then((res) => {
if (res?.data) {
for (let i in res.data.map) {
var obj = {
label: i,
value: res.data.map[i],
}
this.total = this.total + res.data.map[i]
this.statisticsList.push(obj)
}
}
})
},
toList(label) {
uni.navigateTo({ url: `./List?label=${label}`})
}
},
created() {
this.getStatistic()
},
onShow() {
document.title = "特殊人群"
},