|
@@ -1,7 +1,7 @@
|
1
|
1
|
<template>
|
2
|
2
|
<div class="mainPage" v-if="show">
|
3
|
|
- <video :src="data.VideoUrl" height="100%" width="100%" preload="auto" ></video>
|
4
|
|
- <!-- <div class="residue">
|
|
3
|
+ <!-- <video :src="data.VideoUrl" height="100%" width="100%" preload="auto" ></video> -->
|
|
4
|
+ <div class="residue">
|
5
|
5
|
<i class="iconfont icon-gantanhao"></i>
|
6
|
6
|
<span>仅剩{{data.TotalCount - data.SentCount}}张券可以领取!</span>
|
7
|
7
|
</div>
|
|
@@ -44,7 +44,7 @@
|
44
|
44
|
<div class="submit" v-if="button && data.TotalCount - data.SentCount > 0" @click="receive">确认领取</div>
|
45
|
45
|
<div class="submit grays" v-if="button && data.TotalCount - data.SentCount <= 0">优惠券已领完</div>
|
46
|
46
|
<div class="submit" v-if="!button">点击右上角分享给客户</div>
|
47
|
|
- </div> -->
|
|
47
|
+ </div>
|
48
|
48
|
</div>
|
49
|
49
|
</template>
|
50
|
50
|
|
|
@@ -100,7 +100,11 @@ export default {
|
100
|
100
|
if (this.$route.query.type === 'card') {
|
101
|
101
|
this.getCardShare({ id: this.$route.query.id }).then(() => {
|
102
|
102
|
this.data = this.cardShare.Card
|
103
|
|
- this.data.address = this.caseList.filter(x => x.CaseId === this.data.CaseId)[0].CaseAddress
|
|
103
|
+ let arr = this.caseList.filter(x => x.CaseId === this.data.CaseId)
|
|
104
|
+ if (arr.length <= 0) {
|
|
105
|
+ arr.push({ CaseAddress: '' })
|
|
106
|
+ }
|
|
107
|
+ this.data.address = arr[0].CaseAddress
|
104
|
108
|
if (!this.data.VideoUrl) {
|
105
|
109
|
this.video = false
|
106
|
110
|
}
|
|
@@ -110,7 +114,11 @@ export default {
|
110
|
114
|
} else {
|
111
|
115
|
this.getCouponShare({ id: this.$route.query.id }).then(() => {
|
112
|
116
|
this.data = this.couponShare.coupon
|
113
|
|
- this.data.address = this.caseList.filter(x => x.CaseId === this.data.CaseId)[0].CaseAddress
|
|
117
|
+ let arr = this.caseList.filter(x => x.CaseId === this.data.CaseId)
|
|
118
|
+ if (arr.length <= 0) {
|
|
119
|
+ arr.push({ CaseAddress: '' })
|
|
120
|
+ }
|
|
121
|
+ this.data.address = arr[0].CaseAddress
|
114
|
122
|
if (!this.data.VideoUrl) {
|
115
|
123
|
this.video = false
|
116
|
124
|
}
|