|
|
|
|
@ -32,6 +32,7 @@
|
|
|
|
|
|
|
|
|
|
<script>
|
|
|
|
|
import { listByConditons } from "@/api/kaohe/vote"
|
|
|
|
|
import { listVote_recard } from "@/api/kaohe/vote_recard"
|
|
|
|
|
|
|
|
|
|
export default {
|
|
|
|
|
name: "Index",
|
|
|
|
|
@ -67,7 +68,25 @@ export default {
|
|
|
|
|
})
|
|
|
|
|
},
|
|
|
|
|
goVotepage(row){
|
|
|
|
|
this.$router.push({ path: '/votepage', query: { id: row.id }});
|
|
|
|
|
|
|
|
|
|
if(this.$store.state.user.roles.indexOf('admin')>0 || this.$store.state.user.roles.indexOf('sysAdmin')>0){
|
|
|
|
|
this.$router.push({ path: '/votepage', query: { id: row.id }});
|
|
|
|
|
}else {
|
|
|
|
|
listVote_recard({
|
|
|
|
|
pageNum: 1,
|
|
|
|
|
pageSize: 1000000000,
|
|
|
|
|
voteId: row.id,
|
|
|
|
|
userId: this.$store.state.user.id,
|
|
|
|
|
}).then(response => {
|
|
|
|
|
if(response.total>0){
|
|
|
|
|
this.$alert(`已经评分完成,不能再次评分!`, `提示`, {
|
|
|
|
|
type: 'Danger'
|
|
|
|
|
})
|
|
|
|
|
}else {
|
|
|
|
|
this.$router.push({ path: '/votepage', query: { id: row.id }});
|
|
|
|
|
}
|
|
|
|
|
})
|
|
|
|
|
}
|
|
|
|
|
},
|
|
|
|
|
}
|
|
|
|
|
}
|
|
|
|
|
|