51 lines
878 B
Vue
51 lines
878 B
Vue
<template>
|
|
<view style="max-height: 620px; overflow-y: auto;">
|
|
<view v-for="(item,index) in list" :key="index">
|
|
<Card :info="item" />
|
|
</view>
|
|
</view>
|
|
</template>
|
|
|
|
<script>
|
|
import Card from "./card.vue"
|
|
export default {
|
|
props:{
|
|
resCode:String,
|
|
default:''
|
|
},
|
|
components:{
|
|
Card
|
|
},
|
|
data() {
|
|
return {
|
|
list:[]
|
|
}
|
|
},
|
|
|
|
methods: {
|
|
async getData(){
|
|
try{
|
|
const {data} = await uni.$http.post(
|
|
"/gunshiApp/xfflood/reservoir/water/safe/person",
|
|
{
|
|
resCode:this.resCode
|
|
})
|
|
console.log("data",data);
|
|
if(data.code == 200){
|
|
this.list = [...data.data];
|
|
}
|
|
}catch(e){
|
|
uni.$showMsg();
|
|
}
|
|
},
|
|
},
|
|
mounted() {
|
|
this.getData()
|
|
}
|
|
}
|
|
</script>
|
|
|
|
<style>
|
|
|
|
</style>
|