|
@@ -2,7 +2,7 @@
|
2
|
2
|
<div class="context">
|
3
|
3
|
<div class="ContextbBox">
|
4
|
4
|
<span class="personnumber">NO.{{detail.MemberId}}</span>
|
5
|
|
- <span class="votelist">投票列表</span>
|
|
5
|
+ <span class="votelist" @click="tolist">投票列表</span>
|
6
|
6
|
<img :src="detail.Photo">
|
7
|
7
|
<div class="detailinformation">
|
8
|
8
|
<div class="nameinformation">
|
|
@@ -26,11 +26,13 @@
|
26
|
26
|
<span class="dashedline"></span>
|
27
|
27
|
<span class="writeword">寄语:{{detail.Message}}</span>
|
28
|
28
|
</div>
|
|
29
|
+ <toast v-if="show" :url="info.AfterVote" @close="close" @confirmbtn="tolink"></toast>
|
29
|
30
|
</div>
|
30
|
31
|
</template>
|
31
|
32
|
<script>
|
32
|
33
|
import { createNamespacedHelpers } from 'vuex';
|
33
|
34
|
const {mapState: mapVoteState, mapActions: mapVoteActions} = createNamespacedHelpers('vote')
|
|
35
|
+import toast from '../../components/toast.vue'
|
34
|
36
|
|
35
|
37
|
export default {
|
36
|
38
|
name: "votingdetails",
|
|
@@ -38,11 +40,18 @@ export default {
|
38
|
40
|
return {
|
39
|
41
|
actid: '',
|
40
|
42
|
memberid: '',
|
|
43
|
+ show: false,
|
41
|
44
|
};
|
42
|
45
|
},
|
|
46
|
+ components: {
|
|
47
|
+ toast,
|
|
48
|
+ },
|
43
|
49
|
mounted() {
|
44
|
50
|
this.actid = this.$route.params.actid;
|
45
|
51
|
this.memberid = this.$route.params.memberid;
|
|
52
|
+ this.getActivity({
|
|
53
|
+ actid: this.actid,
|
|
54
|
+ })
|
46
|
55
|
this.getMember({
|
47
|
56
|
actid: this.actid,
|
48
|
57
|
memberid: this.memberid,
|
|
@@ -50,6 +59,7 @@ export default {
|
50
|
59
|
},
|
51
|
60
|
computed: {
|
52
|
61
|
...mapVoteState({
|
|
62
|
+ info: x => x.activity,
|
53
|
63
|
detail: x => x.detail,
|
54
|
64
|
user: x => x.user,
|
55
|
65
|
})
|
|
@@ -58,14 +68,32 @@ export default {
|
58
|
68
|
...mapVoteActions([
|
59
|
69
|
'getMember',
|
60
|
70
|
'vote',
|
|
71
|
+ 'getActivity',
|
61
|
72
|
]),
|
62
|
73
|
Vote() {
|
63
|
74
|
this.vote({
|
64
|
75
|
actid: this.actid,
|
65
|
76
|
memberid: this.memberid,
|
66
|
77
|
openid: this.user,
|
|
78
|
+ }).then(() => {
|
|
79
|
+ this.getMember({
|
|
80
|
+ actid: this.actid,
|
|
81
|
+ memberid: this.memberid,
|
|
82
|
+ })
|
|
83
|
+ this.show = true
|
67
|
84
|
})
|
68
|
|
- }
|
|
85
|
+ },
|
|
86
|
+ tolist() {
|
|
87
|
+ this.$router.push({
|
|
88
|
+ path: `/vote/${this.actid}`
|
|
89
|
+ })
|
|
90
|
+ },
|
|
91
|
+ close() {
|
|
92
|
+ this.show = false
|
|
93
|
+ },
|
|
94
|
+ tolink() {
|
|
95
|
+ window.location.href = this.info.AfterVote
|
|
96
|
+ },
|
69
|
97
|
},
|
70
|
98
|
};
|
71
|
99
|
</script>
|