提交 af6d3b84 authored 作者: 王鹏飞's avatar 王鹏飞

bug fixes

上级 f51836a0
......@@ -41,6 +41,8 @@ export default {
<style lang="scss" scoped>
.vote {
padding: 0.2rem;
height: auto;
min-height: 100vh;
}
.box {
margin-bottom: 0.1rem;
......
......@@ -5,7 +5,7 @@
<div class="vote-project" v-for="(item, index) in list" :key="index">
<h2 class="vote-project-title">{{ item.project }}:</h2>
<p class="vote-project-text">
<template v-for="(user, index) in item.candidate">
<template v-for="(user, index) in item.checked">
<span v-if="user.checked" :key="user.id"><template v-if="index"></template>{{ user.name }}</span>
</template>
</p>
......@@ -38,7 +38,10 @@ export default {
return this.$route.query.city
},
list() {
return this.$store.state.voteList
return this.$store.state.voteList.map(item => {
item.checked = item.candidate.filter(item => item.checked)
return item
})
}
},
methods: {
......
Markdown 格式
0%
您添加了 0 到此讨论。请谨慎行事。
请先完成此评论的编辑!
注册 或者 后发表评论