jufubao-base 1.0.158-beta4 → 1.0.158-beta6
This diff represents the content of publicly available package versions that have been released to one of the supported registries. The information contained in this diff is provided for informational purposes only and reflects changes between package versions as they appear in their respective public registries.
- package/package.json +1 -1
- package/src/components/JfbBaseAfterOrderDetail/JfbBaseAfterOrderDetail.vue +2 -2
- package/src/components/JfbBaseCardInfo/JfbBaseCardInfo.vue +0 -1
- package/src/components/JfbBaseCardInfoEntry/JfbBaseCardInfoEntry.vue +0 -1
- package/src/components/JfbBaseConDialog/Api.js +13 -1
- package/src/components/JfbBaseConDialog/JfbBaseConDialog.vue +60 -8
- package/src/components/JfbBaseConDialog/XdCouCardBind.vue +206 -134
- package/src/components/JfbBaseConList/Api.js +13 -1
- package/src/components/JfbBaseConList/JfbBaseConList.vue +333 -108
- package/src/components/JfbBaseConList/Mock.js +1 -1
- package/src/components/JfbBaseOrderDetail/JfbBaseOrderDetail.vue +1 -3
- package/src/components/JfbBaseOrderList/JfbBaseOrderList.vue +1 -1
package/package.json
CHANGED
|
@@ -63,7 +63,7 @@
|
|
|
63
63
|
class="jfb-base-after-order-detail__body-movie-content-info-bottom"
|
|
64
64
|
>
|
|
65
65
|
<view >
|
|
66
|
-
<xd-unit v-if="info.business_icon !== 'gift'
|
|
66
|
+
<xd-unit v-if="info.business_icon !== 'gift'" :price="item.sale_price"></xd-unit>
|
|
67
67
|
</view>
|
|
68
68
|
<view style=" font-size: 28rpx; display: flex; align-items: center; color: #666;">x {{ item.buy_count }}</view>
|
|
69
69
|
</view>
|
|
@@ -80,7 +80,7 @@
|
|
|
80
80
|
:style="{ color: mainColor }"
|
|
81
81
|
>补发快递:{{ info['express_name'] }}</view> -->
|
|
82
82
|
<view v-else :style="{ color: mainColor }">
|
|
83
|
-
<view v-if="info.business_code !== 'gift'
|
|
83
|
+
<view v-if="info.business_code !== 'gift'">
|
|
84
84
|
已退款:¥{{ info.total_refund_sale_amount }}
|
|
85
85
|
</view>
|
|
86
86
|
</view>
|
|
@@ -29,7 +29,7 @@ module.exports = [
|
|
|
29
29
|
disabled: true,
|
|
30
30
|
},
|
|
31
31
|
{
|
|
32
|
-
mapFnName: '
|
|
32
|
+
mapFnName: 'getOnceCoupon', //自定义方法名字(必选)
|
|
33
33
|
title: '领取优惠券',
|
|
34
34
|
path: '/sms-coupon/v1/activity-prizes-user/set',
|
|
35
35
|
isRule: false,
|
|
@@ -40,6 +40,18 @@ module.exports = [
|
|
|
40
40
|
isConsole: true,
|
|
41
41
|
disabled: true,
|
|
42
42
|
},
|
|
43
|
+
{
|
|
44
|
+
mapFnName: 'getAllCoupon', //自定义方法名字(必选)
|
|
45
|
+
title: '领取优惠券',
|
|
46
|
+
path: '/sms-coupon/v1/activity-prizes-user/set-all',
|
|
47
|
+
isRule: false,
|
|
48
|
+
params: {
|
|
49
|
+
distribution_method: ['发放方式 entry=主动发放, homed=首页发放,paid=消费后发放,card_binded=绑定卡后发放', 'String', '选填'],
|
|
50
|
+
namespace: ['业务线', 'String', '必填'],
|
|
51
|
+
},
|
|
52
|
+
isConsole: true,
|
|
53
|
+
disabled: true,
|
|
54
|
+
},
|
|
43
55
|
{
|
|
44
56
|
mapFnName: 'getCouponResult', //自定义方法名字(必选)
|
|
45
57
|
title: '轮询查询活动结果',
|
|
@@ -53,10 +53,13 @@
|
|
|
53
53
|
</view>
|
|
54
54
|
<view v-else class="jfb-base-con-dialog__body-dialog-content">
|
|
55
55
|
<xd-cou-card-bind
|
|
56
|
+
:isAll="isAll"
|
|
57
|
+
:isRandom="isRandom"
|
|
56
58
|
:list="couponList"
|
|
57
59
|
:setting="couponOther"
|
|
58
60
|
@closeDialog="handleCardBindClose"
|
|
59
61
|
@getCoupont="handleGetCoupon"
|
|
62
|
+
@getAllCoupont="getAllCoupont"
|
|
60
63
|
></xd-cou-card-bind>
|
|
61
64
|
</view>
|
|
62
65
|
</view>
|
|
@@ -114,6 +117,8 @@ export default {
|
|
|
114
117
|
//预览是否显示弹窗
|
|
115
118
|
is_preview_hide_dailog: false,
|
|
116
119
|
|
|
120
|
+
isAll: false,
|
|
121
|
+
isRandom: false
|
|
117
122
|
};
|
|
118
123
|
},
|
|
119
124
|
computed: {
|
|
@@ -153,7 +158,7 @@ export default {
|
|
|
153
158
|
//领取优惠券
|
|
154
159
|
handleGetCoupon(item){
|
|
155
160
|
this.$xdShowLoading({});
|
|
156
|
-
jfbRootExec("
|
|
161
|
+
jfbRootExec("getOnceCoupon", {
|
|
157
162
|
vm: this,
|
|
158
163
|
data: {
|
|
159
164
|
prize_id: item.prize_id,
|
|
@@ -182,7 +187,6 @@ export default {
|
|
|
182
187
|
},
|
|
183
188
|
|
|
184
189
|
getResult() {
|
|
185
|
-
debugger
|
|
186
190
|
jfbRootExec("getCouponResult", {
|
|
187
191
|
vm: this,
|
|
188
192
|
data: {
|
|
@@ -261,6 +265,7 @@ export default {
|
|
|
261
265
|
this.list[this.currentIndex].app_activity_button
|
|
262
266
|
);
|
|
263
267
|
this.activity_id = this.list[this.currentIndex].activity_id;
|
|
268
|
+
this.isAll =
|
|
264
269
|
this.handlePop();
|
|
265
270
|
})
|
|
266
271
|
.catch((err) => {
|
|
@@ -279,14 +284,27 @@ export default {
|
|
|
279
284
|
const { list, ...other } = res;
|
|
280
285
|
this.couponList = list;
|
|
281
286
|
this.couponOther = other;
|
|
282
|
-
|
|
287
|
+
this.isAll = res.receive_method==="batch"
|
|
288
|
+
this.isRandom = res.distribution_type==="random"
|
|
289
|
+
this.activity_id = res.activity_id
|
|
290
|
+
if(res.receive_method !== "batch") {
|
|
291
|
+
if(res.can_take === "Y" && res.has_times === "Y" && list.length > 0){
|
|
292
|
+
if (this.isPreview) {
|
|
293
|
+
console.log(getContainerPropsValue(value, "content.is_show_dailog", 'Y'))
|
|
294
|
+
this.isShow = getContainerPropsValue(value, "content.is_show_dailog", 'Y') === 'N';
|
|
295
|
+
}else this.isShow = true;
|
|
296
|
+
}else{
|
|
297
|
+
this.handleCardBindClose();
|
|
298
|
+
}
|
|
299
|
+
} else {
|
|
300
|
+
if(res.can_take === "Y"){
|
|
283
301
|
if (this.isPreview) {
|
|
284
|
-
debugger
|
|
285
302
|
console.log(getContainerPropsValue(value, "content.is_show_dailog", 'Y'))
|
|
286
303
|
this.isShow = getContainerPropsValue(value, "content.is_show_dailog", 'Y') === 'N';
|
|
287
|
-
|
|
288
|
-
|
|
289
|
-
|
|
304
|
+
}else this.isShow = true;
|
|
305
|
+
}else{
|
|
306
|
+
this.handleCardBindClose();
|
|
307
|
+
}
|
|
290
308
|
}
|
|
291
309
|
})
|
|
292
310
|
},
|
|
@@ -299,6 +317,41 @@ export default {
|
|
|
299
317
|
}
|
|
300
318
|
},
|
|
301
319
|
|
|
320
|
+
getAllCoupont(info) {
|
|
321
|
+
this.p_getAllDialogList();
|
|
322
|
+
},
|
|
323
|
+
|
|
324
|
+
p_getAllDialogList() {
|
|
325
|
+
//getAllCoupon
|
|
326
|
+
this.$xdShowLoading({});
|
|
327
|
+
jfbRootExec("getAllCoupon", {
|
|
328
|
+
vm: this,
|
|
329
|
+
data: {
|
|
330
|
+
distribution_method: this.distribution_method,
|
|
331
|
+
activity_id: this.activity_id,
|
|
332
|
+
...this.dispatchData
|
|
333
|
+
}
|
|
334
|
+
}).then(res => {
|
|
335
|
+
if (res.code === 400) {
|
|
336
|
+
this.$xdHideLoading();
|
|
337
|
+
this.$xdAlert({
|
|
338
|
+
content: res.message,
|
|
339
|
+
zIndex: 3200,
|
|
340
|
+
time: 2000,
|
|
341
|
+
isClose: false,
|
|
342
|
+
});
|
|
343
|
+
this.getDialogList();
|
|
344
|
+
return;
|
|
345
|
+
}
|
|
346
|
+
this.order_num = res.tmp_order_number;
|
|
347
|
+
setTimeout(()=>{
|
|
348
|
+
this.getResult();
|
|
349
|
+
},1000)
|
|
350
|
+
}).catch((err) => {
|
|
351
|
+
console.log(err, "err");
|
|
352
|
+
});
|
|
353
|
+
},
|
|
354
|
+
|
|
302
355
|
handlePop() {
|
|
303
356
|
console.warn(`this.time${this.time * 60 + "分钟"}`);
|
|
304
357
|
storage.set(this.containerId, 1, this.time);
|
|
@@ -320,7 +373,6 @@ export default {
|
|
|
320
373
|
){
|
|
321
374
|
this.getDialogList();
|
|
322
375
|
}
|
|
323
|
-
|
|
324
376
|
//支付跟绑卡是主动触发
|
|
325
377
|
if(this.distribution_method === 'card_binded'){
|
|
326
378
|
jfbRootFnExec(this, 'onCustomEvent')("baseConDialog@hasCon", this.containerId);
|
|
@@ -3,34 +3,90 @@
|
|
|
3
3
|
<view
|
|
4
4
|
class="ticket_box"
|
|
5
5
|
:style="{
|
|
6
|
-
|
|
6
|
+
backgroundImage: dialogBackground,
|
|
7
7
|
}"
|
|
8
8
|
>
|
|
9
|
-
<view
|
|
10
|
-
<view
|
|
11
|
-
|
|
12
|
-
|
|
13
|
-
|
|
14
|
-
|
|
15
|
-
|
|
16
|
-
|
|
17
|
-
<
|
|
18
|
-
|
|
9
|
+
<view v-if="isAll">
|
|
10
|
+
<view v-if="!isRandom" class="ticket_list">
|
|
11
|
+
<view
|
|
12
|
+
class="ticket_item"
|
|
13
|
+
:class="item.can_take_num"
|
|
14
|
+
v-for="(item, i) in uiList"
|
|
15
|
+
:key="i"
|
|
16
|
+
>
|
|
17
|
+
<view class="item_head">
|
|
18
|
+
<image
|
|
19
|
+
class="t_icon"
|
|
20
|
+
mode="widthFix"
|
|
21
|
+
:src="item.headIcon"
|
|
22
|
+
></image>
|
|
23
|
+
<view>{{ item.prize_type }}</view>
|
|
24
|
+
</view>
|
|
25
|
+
<view class="item_sub">{{ item.prize_name }}</view>
|
|
26
|
+
|
|
27
|
+
<xd-font-icon
|
|
28
|
+
class="ticket_icon"
|
|
29
|
+
:color="item.iconColor"
|
|
30
|
+
:icon="item.icon"
|
|
31
|
+
></xd-font-icon>
|
|
19
32
|
</view>
|
|
20
|
-
|
|
33
|
+
</view>
|
|
34
|
+
<view v-else>
|
|
35
|
+
<img
|
|
36
|
+
style="width: 100%"
|
|
37
|
+
mode="widthFix"
|
|
38
|
+
:src="bottomBackground"
|
|
39
|
+
alt=""
|
|
40
|
+
/>
|
|
41
|
+
</view>
|
|
42
|
+
<xd-button
|
|
43
|
+
size="small"
|
|
44
|
+
type="primary"
|
|
45
|
+
:style="{
|
|
46
|
+
backgroundImage: btnImage,
|
|
47
|
+
backgroundSize: '100% 100%',
|
|
48
|
+
width: '80%'
|
|
49
|
+
}"
|
|
50
|
+
@click="getAllCoupont"
|
|
51
|
+
>{{ isRandom ? "开心获取" : "一键领取" }}</xd-button
|
|
52
|
+
>
|
|
53
|
+
</view>
|
|
54
|
+
<view v-else>
|
|
55
|
+
<view class="ticket_list">
|
|
56
|
+
<view
|
|
57
|
+
class="ticket_item"
|
|
58
|
+
:class="item.can_take_num"
|
|
59
|
+
v-for="(item, i) in uiList"
|
|
60
|
+
:key="i"
|
|
61
|
+
>
|
|
62
|
+
<view class="item_head">
|
|
63
|
+
<image
|
|
64
|
+
class="t_icon"
|
|
65
|
+
mode="widthFix"
|
|
66
|
+
:src="item.headIcon"
|
|
67
|
+
></image>
|
|
68
|
+
<view>{{ item.prize_type }}</view>
|
|
69
|
+
</view>
|
|
70
|
+
<view class="item_sub">{{ item.prize_name }}</view>
|
|
21
71
|
|
|
22
|
-
|
|
23
|
-
|
|
24
|
-
|
|
25
|
-
|
|
26
|
-
|
|
27
|
-
|
|
28
|
-
|
|
29
|
-
|
|
30
|
-
|
|
31
|
-
|
|
32
|
-
|
|
33
|
-
|
|
72
|
+
<xd-font-icon
|
|
73
|
+
class="ticket_icon"
|
|
74
|
+
:color="item.iconColor"
|
|
75
|
+
:icon="item.icon"
|
|
76
|
+
></xd-font-icon>
|
|
77
|
+
<view class="btn">
|
|
78
|
+
<xd-button
|
|
79
|
+
size="small"
|
|
80
|
+
type="primary"
|
|
81
|
+
:disabled="item.remain_card_count == 0"
|
|
82
|
+
:style="{
|
|
83
|
+
backgroundImage: item.btnImage,
|
|
84
|
+
backgroundSize: '100% 100%',
|
|
85
|
+
}"
|
|
86
|
+
@click="getCoupont(item)"
|
|
87
|
+
>{{ item.btn_txt }}</xd-button
|
|
88
|
+
>
|
|
89
|
+
</view>
|
|
34
90
|
</view>
|
|
35
91
|
</view>
|
|
36
92
|
</view>
|
|
@@ -49,157 +105,173 @@
|
|
|
49
105
|
import XdButton from "@/components/XdButton/XdButton";
|
|
50
106
|
import XdFontIcon from "@/components/XdFontIcon/XdFontIcon";
|
|
51
107
|
import getServiceUrl from "@/common/getServiceUrl";
|
|
52
|
-
export default{
|
|
108
|
+
export default {
|
|
53
109
|
name: "XdCouCardBind",
|
|
54
110
|
components: {
|
|
55
111
|
XdButton,
|
|
56
|
-
XdFontIcon
|
|
112
|
+
XdFontIcon,
|
|
57
113
|
},
|
|
58
114
|
props: {
|
|
59
115
|
list: {
|
|
60
116
|
type: Array,
|
|
61
|
-
default(){
|
|
62
|
-
return []
|
|
63
|
-
}
|
|
117
|
+
default() {
|
|
118
|
+
return [];
|
|
119
|
+
},
|
|
120
|
+
},
|
|
121
|
+
isAll: {
|
|
122
|
+
type: Boolean,
|
|
123
|
+
default: false,
|
|
124
|
+
},
|
|
125
|
+
isRandom: {
|
|
126
|
+
type: Boolean,
|
|
127
|
+
default: false,
|
|
64
128
|
},
|
|
65
|
-
|
|
129
|
+
btnImage: {
|
|
130
|
+
type: String,
|
|
131
|
+
default: "",
|
|
132
|
+
},
|
|
133
|
+
setting: {},
|
|
66
134
|
},
|
|
67
135
|
computed: {
|
|
68
|
-
uiList(){
|
|
69
|
-
return this.list.map(item => {
|
|
70
|
-
let mapArr = {
|
|
136
|
+
uiList() {
|
|
137
|
+
return this.list.map((item) => {
|
|
138
|
+
let mapArr = { Y: "去查看", P: "领取", N: "已发完" };
|
|
71
139
|
item.btn_txt = mapArr[item.can_take_num];
|
|
72
|
-
if(item.can_take_num === "Y" || item.can_take_num === "P"){
|
|
140
|
+
if (item.can_take_num === "Y" || item.can_take_num === "P") {
|
|
73
141
|
item.headIcon = getServiceUrl(this.setting.app_coupon_url);
|
|
74
|
-
item.btnImage = `url(${getServiceUrl(
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
142
|
+
item.btnImage = `url(${getServiceUrl(
|
|
143
|
+
this.setting.app_coupon_button_bg_url
|
|
144
|
+
)})`;
|
|
145
|
+
item.icon =
|
|
146
|
+
item.can_take_num === "Y" ? "iconyilingqu" : "icondailingqu";
|
|
147
|
+
item.iconColor = item.can_take_num === "Y" ? "#D6D6D6" : "#FF4D4A";
|
|
148
|
+
} else if (item.can_take_num === "N") {
|
|
78
149
|
item.headIcon = getServiceUrl(this.setting.app_coupon_invalid_url);
|
|
79
150
|
item.btnImage = "";
|
|
80
151
|
item.icon = "iconyifawan";
|
|
81
|
-
item.iconColor =
|
|
152
|
+
item.iconColor = "#D6D6D6";
|
|
82
153
|
}
|
|
83
154
|
return item;
|
|
84
|
-
})
|
|
155
|
+
});
|
|
85
156
|
},
|
|
86
|
-
dialogBackground(){
|
|
157
|
+
dialogBackground() {
|
|
87
158
|
return `url(${getServiceUrl(this.setting.background)})`;
|
|
88
|
-
}
|
|
159
|
+
},
|
|
160
|
+
bottomBackground() {
|
|
161
|
+
return getServiceUrl(this.setting.app_coupon_bottom_url);
|
|
162
|
+
},
|
|
89
163
|
},
|
|
90
|
-
data(){
|
|
91
|
-
return {
|
|
92
|
-
|
|
93
|
-
}
|
|
164
|
+
data() {
|
|
165
|
+
return {};
|
|
94
166
|
},
|
|
95
167
|
methods: {
|
|
96
168
|
//领取优惠券
|
|
97
|
-
getCoupont(item){
|
|
98
|
-
if(item.can_take_num === "P"){
|
|
169
|
+
getCoupont(item) {
|
|
170
|
+
if (item.can_take_num === "P") {
|
|
99
171
|
this.$emit("getCoupont", item);
|
|
100
172
|
}
|
|
101
173
|
},
|
|
102
|
-
|
|
174
|
+
getAllCoupont() {
|
|
175
|
+
this.$emit("getAllCoupont");
|
|
176
|
+
},
|
|
177
|
+
handleClose() {
|
|
103
178
|
this.$emit("closeDialog");
|
|
104
|
-
}
|
|
105
|
-
}
|
|
106
|
-
}
|
|
179
|
+
},
|
|
180
|
+
},
|
|
181
|
+
};
|
|
107
182
|
</script>
|
|
108
183
|
|
|
109
184
|
<style lang="less" scoped>
|
|
110
185
|
@ticketHeight: 180rpx;
|
|
111
186
|
@bgHeight: @ticketHeight - 40rpx;
|
|
112
|
-
|
|
113
|
-
|
|
114
|
-
|
|
115
|
-
|
|
116
|
-
|
|
117
|
-
|
|
118
|
-
|
|
119
|
-
|
|
120
|
-
|
|
121
|
-
|
|
122
|
-
|
|
123
|
-
|
|
124
|
-
|
|
125
|
-
|
|
126
|
-
.ticket_item{
|
|
127
|
-
display: flex;
|
|
128
|
-
flex-direction: column;
|
|
129
|
-
position: relative;
|
|
130
|
-
width: 540rpx;
|
|
131
|
-
height: @ticketHeight;
|
|
132
|
-
margin: 20rpx auto;
|
|
133
|
-
border-radius: 20rpx;
|
|
134
|
-
padding: 30rpx;
|
|
135
|
-
box-sizing: border-box;
|
|
136
|
-
background: #FFF8F8;
|
|
187
|
+
.xd-cou-card-bind {
|
|
188
|
+
width: 600rpx;
|
|
189
|
+
max-height: 900rpx;
|
|
190
|
+
padding-bottom: 80rpx;
|
|
191
|
+
.ticket_box {
|
|
192
|
+
background-color: #fff;
|
|
193
|
+
background-size: 100% auto;
|
|
194
|
+
background-repeat: no-repeat;
|
|
195
|
+
padding-top: 200rpx;
|
|
196
|
+
border-radius: 20rpx;
|
|
197
|
+
box-sizing: border-box;
|
|
198
|
+
padding-bottom: 20rpx;
|
|
199
|
+
}
|
|
137
200
|
|
|
138
|
-
|
|
139
|
-
|
|
201
|
+
.ticket_item {
|
|
202
|
+
display: flex;
|
|
203
|
+
flex-direction: column;
|
|
204
|
+
position: relative;
|
|
205
|
+
width: 540rpx;
|
|
206
|
+
height: @ticketHeight;
|
|
207
|
+
margin: 20rpx auto;
|
|
208
|
+
border-radius: 20rpx;
|
|
209
|
+
padding: 30rpx;
|
|
210
|
+
box-sizing: border-box;
|
|
211
|
+
background: #fff8f8;
|
|
140
212
|
|
|
213
|
+
&.P,
|
|
214
|
+
&.Y {
|
|
215
|
+
}
|
|
216
|
+
&.N {
|
|
217
|
+
background: #f3f3f3;
|
|
218
|
+
.item_head {
|
|
219
|
+
color: #bbbbbb;
|
|
141
220
|
}
|
|
142
|
-
|
|
143
|
-
|
|
144
|
-
.item_head{
|
|
145
|
-
color: #BBBBBB;
|
|
146
|
-
}
|
|
147
|
-
.item_sub{
|
|
148
|
-
color: #BBBBBB;
|
|
149
|
-
}
|
|
150
|
-
.ticket_icon{
|
|
151
|
-
color: #D6D6D6;
|
|
152
|
-
|
|
153
|
-
}
|
|
154
|
-
.btn{
|
|
155
|
-
.xd-button{
|
|
156
|
-
background-color: #DDDDDD !important;
|
|
157
|
-
color: #999999 !important;
|
|
158
|
-
}
|
|
159
|
-
}
|
|
160
|
-
}
|
|
161
|
-
.item_head{
|
|
162
|
-
display: flex;
|
|
163
|
-
align-items: center;
|
|
164
|
-
font-size: 40rpx;
|
|
165
|
-
color: #000000;
|
|
166
|
-
font-weight: 500;
|
|
167
|
-
.t_icon{
|
|
168
|
-
width: 44rpx;
|
|
169
|
-
margin-right: 20rpx;
|
|
170
|
-
}
|
|
171
|
-
}
|
|
172
|
-
.item_sub{
|
|
173
|
-
margin-top: 20rpx;
|
|
174
|
-
color: #FF4D4A;
|
|
175
|
-
font-size: 36rpx;
|
|
176
|
-
font-weight: 400;
|
|
221
|
+
.item_sub {
|
|
222
|
+
color: #bbbbbb;
|
|
177
223
|
}
|
|
178
|
-
.ticket_icon{
|
|
179
|
-
|
|
180
|
-
position: absolute;
|
|
181
|
-
top: 0;
|
|
182
|
-
right: 0;
|
|
224
|
+
.ticket_icon {
|
|
225
|
+
color: #d6d6d6;
|
|
183
226
|
}
|
|
184
|
-
.btn{
|
|
185
|
-
|
|
186
|
-
|
|
187
|
-
|
|
188
|
-
.xd-button{
|
|
189
|
-
height: 30rpx;
|
|
190
|
-
width: 100rpx;
|
|
191
|
-
font-size: 28rpx;
|
|
192
|
-
background-size: cover !important;
|
|
193
|
-
background-color: #fb5b3f;
|
|
227
|
+
.btn {
|
|
228
|
+
.xd-button {
|
|
229
|
+
background-color: #dddddd !important;
|
|
230
|
+
color: #999999 !important;
|
|
194
231
|
}
|
|
195
232
|
}
|
|
196
|
-
|
|
197
233
|
}
|
|
198
|
-
.
|
|
234
|
+
.item_head {
|
|
235
|
+
display: flex;
|
|
236
|
+
align-items: center;
|
|
237
|
+
font-size: 40rpx;
|
|
238
|
+
color: #000000;
|
|
239
|
+
font-weight: 500;
|
|
240
|
+
.t_icon {
|
|
241
|
+
width: 44rpx;
|
|
242
|
+
margin-right: 20rpx;
|
|
243
|
+
}
|
|
244
|
+
}
|
|
245
|
+
.item_sub {
|
|
246
|
+
margin-top: 20rpx;
|
|
247
|
+
color: #ff4d4a;
|
|
248
|
+
font-size: 36rpx;
|
|
249
|
+
font-weight: 400;
|
|
250
|
+
}
|
|
251
|
+
.ticket_icon {
|
|
252
|
+
font-size: 80rpx !important;
|
|
199
253
|
position: absolute;
|
|
200
|
-
|
|
201
|
-
|
|
202
|
-
|
|
254
|
+
top: 0;
|
|
255
|
+
right: 0;
|
|
256
|
+
}
|
|
257
|
+
.btn {
|
|
258
|
+
position: absolute;
|
|
259
|
+
right: 20rpx;
|
|
260
|
+
bottom: 20rpx;
|
|
261
|
+
.xd-button {
|
|
262
|
+
height: 30rpx;
|
|
263
|
+
width: 100rpx;
|
|
264
|
+
font-size: 28rpx;
|
|
265
|
+
background-size: cover !important;
|
|
266
|
+
background-color: #fb5b3f;
|
|
267
|
+
}
|
|
203
268
|
}
|
|
204
269
|
}
|
|
270
|
+
.dialog_close {
|
|
271
|
+
position: absolute;
|
|
272
|
+
bottom: 0rpx;
|
|
273
|
+
left: 50%;
|
|
274
|
+
transform: translateX(-50%);
|
|
275
|
+
}
|
|
276
|
+
}
|
|
205
277
|
</style>
|
|
@@ -33,7 +33,7 @@ module.exports = [
|
|
|
33
33
|
disabled: true,
|
|
34
34
|
},
|
|
35
35
|
{
|
|
36
|
-
mapFnName: '
|
|
36
|
+
mapFnName: 'getOnceCoupon', //自定义方法名字(必选)
|
|
37
37
|
title: '领取优惠券',
|
|
38
38
|
path: '/sms-coupon/v1/activity-prizes-user/set',
|
|
39
39
|
isRule: false,
|
|
@@ -44,6 +44,18 @@ module.exports = [
|
|
|
44
44
|
isConsole: true,
|
|
45
45
|
disabled: true,
|
|
46
46
|
},
|
|
47
|
+
{
|
|
48
|
+
mapFnName: 'getAllCoupon', //自定义方法名字(必选)
|
|
49
|
+
title: '领取优惠券',
|
|
50
|
+
path: '/sms-coupon/v1/activity-prizes-user/set-all',
|
|
51
|
+
isRule: false,
|
|
52
|
+
params: {
|
|
53
|
+
distribution_method: ['发放方式 entry=主动发放, homed=首页发放,paid=消费后发放,card_binded=绑定卡后发放', 'String', '选填'],
|
|
54
|
+
namespace: ['业务线', 'String', '必填'],
|
|
55
|
+
},
|
|
56
|
+
isConsole: true,
|
|
57
|
+
disabled: true,
|
|
58
|
+
},
|
|
47
59
|
{
|
|
48
60
|
mapFnName: 'getCouponResult', //自定义方法名字(必选)
|
|
49
61
|
title: '轮询查询活动结果',
|
|
@@ -24,9 +24,9 @@
|
|
|
24
24
|
backgroundSize: '100%',
|
|
25
25
|
backgroundRepeat: 'no-repeat',
|
|
26
26
|
minHeight: `${layoutInfo.bodyMinHeightRpx}rpx`,
|
|
27
|
-
|
|
27
|
+
}"
|
|
28
28
|
>
|
|
29
|
-
<view v-if="
|
|
29
|
+
<view v-if="!message">
|
|
30
30
|
<view class="jfb-base-con-list__body-content">
|
|
31
31
|
<view class="jfb-base-con-list__body-content-header">
|
|
32
32
|
<view class="jfb-base-con-list__body-content-header-left">
|
|
@@ -34,7 +34,10 @@
|
|
|
34
34
|
<view>赠送优惠券</view>
|
|
35
35
|
</view>
|
|
36
36
|
<view
|
|
37
|
-
:style="{
|
|
37
|
+
:style="{
|
|
38
|
+
color: '#FA2125',
|
|
39
|
+
backgroundColor: contentBackground,
|
|
40
|
+
}"
|
|
38
41
|
class="jfb-base-con-list__body-content-header-right"
|
|
39
42
|
@click="showRule = true"
|
|
40
43
|
>
|
|
@@ -42,64 +45,162 @@
|
|
|
42
45
|
<xd-font-icon size="20" icon="iconxiangyou_xian"></xd-font-icon>
|
|
43
46
|
</view>
|
|
44
47
|
</view>
|
|
45
|
-
|
|
46
|
-
|
|
48
|
+
|
|
49
|
+
<view v-if="isAll">
|
|
50
|
+
<view v-if="isRandom">
|
|
51
|
+
<view class="jfb-base-con-list__body-content-list">
|
|
52
|
+
<view>
|
|
53
|
+
<img
|
|
54
|
+
style="width: 100%"
|
|
55
|
+
mode="widthFix"
|
|
56
|
+
:src="app_coupon_bottom_url"
|
|
57
|
+
alt=""
|
|
58
|
+
/>
|
|
59
|
+
</view>
|
|
60
|
+
<xd-button
|
|
61
|
+
size="small"
|
|
62
|
+
type="primary"
|
|
63
|
+
:style="btn_style"
|
|
64
|
+
@click="can_take!=='Y'?toCoupon():getAllCoupont()"
|
|
65
|
+
>{{ btn_txt }}</xd-button
|
|
66
|
+
>
|
|
67
|
+
</view>
|
|
68
|
+
</view>
|
|
69
|
+
<view v-else>
|
|
47
70
|
<view
|
|
48
|
-
|
|
49
|
-
|
|
50
|
-
:style="{
|
|
51
|
-
backgroundColor: item.can_take_num==='Y'||item.can_take_num==='P'? contentBackground:'#F3F3F3',
|
|
52
|
-
}"
|
|
71
|
+
v-if="can_take === 'Y'"
|
|
72
|
+
class="jfb-base-con-list__body-content-list"
|
|
53
73
|
>
|
|
54
|
-
<view
|
|
55
|
-
<
|
|
56
|
-
|
|
74
|
+
<view>
|
|
75
|
+
<view v-for="(item, index) in couponList" :key="index">
|
|
76
|
+
<view
|
|
77
|
+
class="jfb-base-con-list__body-content-list-item"
|
|
78
|
+
:class="'status_' + item.can_take_num"
|
|
79
|
+
:style="{
|
|
80
|
+
backgroundColor:
|
|
81
|
+
item.can_take_num === 'Y' ||
|
|
82
|
+
item.can_take_num === 'P'
|
|
83
|
+
? contentBackground
|
|
84
|
+
: '#F3F3F3',
|
|
85
|
+
}"
|
|
86
|
+
>
|
|
87
|
+
<view class="item_head">
|
|
88
|
+
<image
|
|
89
|
+
class="t_icon"
|
|
90
|
+
mode="widthFix"
|
|
91
|
+
:src="item.headIcon"
|
|
92
|
+
></image>
|
|
93
|
+
<view>{{ item.prize_type }}</view>
|
|
94
|
+
</view>
|
|
95
|
+
<view class="item_sub">{{ item.prize_name }}</view>
|
|
96
|
+
<xd-font-icon
|
|
97
|
+
size="100"
|
|
98
|
+
:style="{
|
|
99
|
+
color: item.iconColor,
|
|
100
|
+
position: 'absolute',
|
|
101
|
+
right: '0rpx',
|
|
102
|
+
top: '0rpx',
|
|
103
|
+
}"
|
|
104
|
+
:icon="item.icon"
|
|
105
|
+
></xd-font-icon>
|
|
106
|
+
</view>
|
|
107
|
+
</view>
|
|
57
108
|
</view>
|
|
58
|
-
<
|
|
59
|
-
|
|
60
|
-
|
|
109
|
+
<xd-button
|
|
110
|
+
size="small"
|
|
111
|
+
type="primary"
|
|
112
|
+
:style="btn_style"
|
|
113
|
+
@click="can_take!=='Y'?toCoupon():getAllCoupont()"
|
|
114
|
+
>{{ btn_txt }}</xd-button
|
|
115
|
+
>
|
|
116
|
+
</view>
|
|
117
|
+
<view
|
|
118
|
+
v-else
|
|
119
|
+
class="jfb-base-con-list__body-content-list"
|
|
120
|
+
style="padding-bottom: 60rpx"
|
|
121
|
+
>
|
|
122
|
+
<image mode="widthFix" :src="used_up_url"></image>
|
|
123
|
+
</view>
|
|
124
|
+
</view>
|
|
125
|
+
</view>
|
|
126
|
+
|
|
127
|
+
<view v-else>
|
|
128
|
+
<view
|
|
129
|
+
v-if="can_take === 'Y' && has_times === 'Y'"
|
|
130
|
+
class="jfb-base-con-list__body-content-list"
|
|
131
|
+
>
|
|
132
|
+
<view v-for="(item, index) in couponList" :key="index">
|
|
133
|
+
<view
|
|
134
|
+
class="jfb-base-con-list__body-content-list-item"
|
|
135
|
+
:class="'status_' + item.can_take_num"
|
|
61
136
|
:style="{
|
|
62
|
-
|
|
63
|
-
|
|
64
|
-
|
|
65
|
-
|
|
137
|
+
backgroundColor:
|
|
138
|
+
item.can_take_num === 'Y' || item.can_take_num === 'P'
|
|
139
|
+
? contentBackground
|
|
140
|
+
: '#F3F3F3',
|
|
66
141
|
}"
|
|
67
|
-
|
|
68
|
-
|
|
69
|
-
|
|
70
|
-
|
|
71
|
-
|
|
72
|
-
|
|
73
|
-
|
|
74
|
-
|
|
75
|
-
|
|
76
|
-
|
|
77
|
-
|
|
78
|
-
|
|
142
|
+
>
|
|
143
|
+
<view class="item_head">
|
|
144
|
+
<image
|
|
145
|
+
class="t_icon"
|
|
146
|
+
mode="widthFix"
|
|
147
|
+
:src="item.headIcon"
|
|
148
|
+
></image>
|
|
149
|
+
<view>{{ item.prize_type }}</view>
|
|
150
|
+
</view>
|
|
151
|
+
<view class="item_sub">{{ item.prize_name }}</view>
|
|
152
|
+
<xd-font-icon
|
|
153
|
+
size="100"
|
|
154
|
+
:style="{
|
|
155
|
+
color: item.iconColor,
|
|
156
|
+
position: 'absolute',
|
|
157
|
+
right: '0rpx',
|
|
158
|
+
top: '0rpx',
|
|
159
|
+
}"
|
|
160
|
+
:icon="item.icon"
|
|
161
|
+
></xd-font-icon>
|
|
162
|
+
<view class="btn_wrap">
|
|
163
|
+
<xd-button
|
|
164
|
+
size="small"
|
|
165
|
+
:disabled="
|
|
166
|
+
item.can_take_num !== 'Y' &&
|
|
167
|
+
item.remain_card_count == 0
|
|
168
|
+
"
|
|
169
|
+
@click="getCoupont(item)"
|
|
170
|
+
type="primary"
|
|
171
|
+
style="width: 170rpx; height: 60rpx"
|
|
172
|
+
:style="item.btn"
|
|
173
|
+
:color="item.infoColor"
|
|
174
|
+
>{{ item.btn_txt }}</xd-button
|
|
175
|
+
>
|
|
176
|
+
</view>
|
|
79
177
|
</view>
|
|
80
178
|
</view>
|
|
81
179
|
</view>
|
|
82
|
-
|
|
83
|
-
|
|
84
|
-
|
|
180
|
+
<view
|
|
181
|
+
v-else
|
|
182
|
+
class="jfb-base-con-list__body-content-list"
|
|
183
|
+
style="padding-bottom: 60rpx"
|
|
184
|
+
>
|
|
185
|
+
<image mode="widthFix" :src="used_up_url"></image>
|
|
186
|
+
</view>
|
|
85
187
|
</view>
|
|
86
188
|
</view>
|
|
87
|
-
<view class="jfb-base-con-list__body-content-foot" @click="toCoupon"
|
|
189
|
+
<view class="jfb-base-con-list__body-content-foot" @click="toCoupon">
|
|
88
190
|
<view
|
|
89
191
|
:style="{
|
|
90
|
-
|
|
91
|
-
|
|
92
|
-
|
|
93
|
-
|
|
94
|
-
|
|
95
|
-
|
|
96
|
-
|
|
192
|
+
padding: outPadding,
|
|
193
|
+
border: border,
|
|
194
|
+
borderRadius: radius + 'rpx',
|
|
195
|
+
color: btnTextColor,
|
|
196
|
+
backgroundColor: btnBgColor,
|
|
197
|
+
boxShadow: shadow,
|
|
198
|
+
}"
|
|
199
|
+
>查看已领票券</view
|
|
200
|
+
>
|
|
97
201
|
</view>
|
|
98
202
|
</view>
|
|
99
|
-
<view
|
|
100
|
-
v-else
|
|
101
|
-
class="empty_data"
|
|
102
|
-
>
|
|
203
|
+
<view v-else class="empty_data">
|
|
103
204
|
<image :src="emptyBg"></image>
|
|
104
205
|
{{ message }}
|
|
105
206
|
</view>
|
|
@@ -109,7 +210,10 @@
|
|
|
109
210
|
title="活动规则说明"
|
|
110
211
|
:show.sync="showRule"
|
|
111
212
|
>
|
|
112
|
-
<xd-content-xss
|
|
213
|
+
<xd-content-xss
|
|
214
|
+
style="text-align: left"
|
|
215
|
+
:html="notice"
|
|
216
|
+
></xd-content-xss>
|
|
113
217
|
</xd-dailog>
|
|
114
218
|
</view>
|
|
115
219
|
</view>
|
|
@@ -167,18 +271,23 @@ export default {
|
|
|
167
271
|
collectedPath: "",
|
|
168
272
|
|
|
169
273
|
//按钮设置
|
|
170
|
-
btnBgColor:
|
|
171
|
-
btnTextColor:
|
|
172
|
-
padding:{},
|
|
274
|
+
btnBgColor: "",
|
|
275
|
+
btnTextColor: "",
|
|
276
|
+
padding: {},
|
|
173
277
|
radius: 0,
|
|
174
278
|
//边框
|
|
175
|
-
is_border:
|
|
176
|
-
is_border_c:
|
|
177
|
-
is_border_w:
|
|
279
|
+
is_border: "N",
|
|
280
|
+
is_border_c: "",
|
|
281
|
+
is_border_w: "",
|
|
178
282
|
//投影
|
|
179
|
-
is_shadow:
|
|
283
|
+
is_shadow: "Y",
|
|
180
284
|
is_shadow_bg: 0,
|
|
181
285
|
is_shadow_w: 0,
|
|
286
|
+
|
|
287
|
+
isAll: false,
|
|
288
|
+
isRandom: false,
|
|
289
|
+
btn_txt: "",
|
|
290
|
+
btn_style: {},
|
|
182
291
|
};
|
|
183
292
|
},
|
|
184
293
|
computed: {
|
|
@@ -191,15 +300,17 @@ export default {
|
|
|
191
300
|
str = `${str} ${this.checkValue(this.padding.right, 0)}rpx`;
|
|
192
301
|
str = `${str} ${this.checkValue(this.padding.bottom, 0)}rpx`;
|
|
193
302
|
str = `${str} ${this.checkValue(this.padding.left, 0)}rpx`;
|
|
194
|
-
return str
|
|
303
|
+
return str;
|
|
195
304
|
},
|
|
196
305
|
border() {
|
|
197
|
-
if (this.is_border ===
|
|
198
|
-
|
|
306
|
+
if (this.is_border === "Y")
|
|
307
|
+
return `${this.is_border_w}rpx solid ${this.is_border_c}`;
|
|
308
|
+
else return "0";
|
|
199
309
|
},
|
|
200
|
-
shadow(){
|
|
201
|
-
if(this.is_shadow ===
|
|
202
|
-
|
|
310
|
+
shadow() {
|
|
311
|
+
if (this.is_shadow === "Y")
|
|
312
|
+
return `0 0 ${this.is_shadow_w}rpx ${this.is_shadow_bg}`;
|
|
313
|
+
else return "0 0 0 rgba(0,0,0,0)";
|
|
203
314
|
},
|
|
204
315
|
},
|
|
205
316
|
watch: {
|
|
@@ -217,22 +328,50 @@ export default {
|
|
|
217
328
|
},
|
|
218
329
|
methods: {
|
|
219
330
|
init(value) {
|
|
220
|
-
this.contentBackground =
|
|
221
|
-
this.iconColor =
|
|
222
|
-
this.collectedPath = getContainerPropsValue(
|
|
331
|
+
this.contentBackground = "#FFF8F8";
|
|
332
|
+
this.iconColor = "#FF4D4A";
|
|
333
|
+
this.collectedPath = getContainerPropsValue(
|
|
334
|
+
value,
|
|
335
|
+
"content.collectedPath",
|
|
336
|
+
{ value: "" }
|
|
337
|
+
).value;
|
|
223
338
|
|
|
224
339
|
this.padding = getContainerPropsValue(value, "content.padding", {});
|
|
225
|
-
this.btnBgColor = getContainerPropsValue(
|
|
226
|
-
|
|
227
|
-
|
|
340
|
+
this.btnBgColor = getContainerPropsValue(
|
|
341
|
+
value,
|
|
342
|
+
"content.btnBgColor",
|
|
343
|
+
"rgba(0,0,0,0)"
|
|
344
|
+
);
|
|
345
|
+
this.btnTextColor = getContainerPropsValue(
|
|
346
|
+
value,
|
|
347
|
+
"content.btnTextColor",
|
|
348
|
+
"#666"
|
|
349
|
+
);
|
|
350
|
+
this.radius = getContainerPropsValue(value, "content.radius", "0");
|
|
228
351
|
|
|
229
|
-
this.is_border = getContainerPropsValue(value, "content.is_border",
|
|
230
|
-
this.is_border_c = getContainerPropsValue(
|
|
231
|
-
|
|
352
|
+
this.is_border = getContainerPropsValue(value, "content.is_border", "N");
|
|
353
|
+
this.is_border_c = getContainerPropsValue(
|
|
354
|
+
value,
|
|
355
|
+
"content.is_border_c",
|
|
356
|
+
"#e5e5e5"
|
|
357
|
+
);
|
|
358
|
+
this.is_border_w = getContainerPropsValue(
|
|
359
|
+
value,
|
|
360
|
+
"content.is_border_w",
|
|
361
|
+
1
|
|
362
|
+
);
|
|
232
363
|
|
|
233
|
-
this.is_shadow = getContainerPropsValue(value,
|
|
234
|
-
this.is_shadow_bg = getContainerPropsValue(
|
|
235
|
-
|
|
364
|
+
this.is_shadow = getContainerPropsValue(value, "content.is_shadow", "N");
|
|
365
|
+
this.is_shadow_bg = getContainerPropsValue(
|
|
366
|
+
value,
|
|
367
|
+
"content.is_shadow_bg",
|
|
368
|
+
"#fff"
|
|
369
|
+
);
|
|
370
|
+
this.is_shadow_w = getContainerPropsValue(
|
|
371
|
+
value,
|
|
372
|
+
"content.is_shadow_w",
|
|
373
|
+
"10"
|
|
374
|
+
);
|
|
236
375
|
},
|
|
237
376
|
|
|
238
377
|
getList() {
|
|
@@ -248,30 +387,77 @@ export default {
|
|
|
248
387
|
.then((res) => {
|
|
249
388
|
this.background = getServiceUrl(res.background);
|
|
250
389
|
this.used_up_url = res.used_up_url && getServiceUrl(res.used_up_url);
|
|
390
|
+
this.app_activity_button =
|
|
391
|
+
res.app_activity_button && getServiceUrl(res.app_activity_button);
|
|
392
|
+
this.app_activity_url =
|
|
393
|
+
res.app_activity_url && getServiceUrl(res.app_activity_url);
|
|
394
|
+
this.app_coupon_bottom_url =
|
|
395
|
+
res.app_coupon_bottom_url &&
|
|
396
|
+
getServiceUrl(res.app_coupon_bottom_url);
|
|
251
397
|
this.can_take = res.can_take;
|
|
252
398
|
this.has_times = res.has_times;
|
|
253
399
|
this.next_url = res.next_url;
|
|
400
|
+
this.isAll = res.receive_method === "batch";
|
|
401
|
+
this.isRandom = res.distribution_type === "random";
|
|
402
|
+
// 判断是否是一键领取
|
|
403
|
+
if (this.isAll) {
|
|
404
|
+
// 定义按钮文字
|
|
405
|
+
let btn_txt = "";
|
|
406
|
+
// 设置按钮样式
|
|
407
|
+
this.btn_style = res.app_coupon_button_bg_url
|
|
408
|
+
? {
|
|
409
|
+
// 设置背景图片
|
|
410
|
+
backgroundImage: `url(${getServiceUrl(
|
|
411
|
+
res.can_take !== "Y"
|
|
412
|
+
? res.app_coupon_button_see_url
|
|
413
|
+
: res.app_coupon_button_bg_url
|
|
414
|
+
)})`,
|
|
415
|
+
// 设置背景大小
|
|
416
|
+
backgroundSize: "100% 100%",
|
|
417
|
+
// 设置背景重复
|
|
418
|
+
backgroundRepeat: "no-repeat",
|
|
419
|
+
// 设置背景颜色
|
|
420
|
+
backgroundColor: "",
|
|
421
|
+
// 设置外边距
|
|
422
|
+
margin: "0",
|
|
423
|
+
}
|
|
424
|
+
: {
|
|
425
|
+
// 设置背景颜色
|
|
426
|
+
backgroundColor: "#FB5B3F",
|
|
427
|
+
// 设置外边距
|
|
428
|
+
margin: "0",
|
|
429
|
+
};
|
|
430
|
+
// 设置按钮文字
|
|
431
|
+
btn_txt = res.can_take === "Y" ? "一键领取" : "去查看";
|
|
432
|
+
// 判断是否是随机领取
|
|
433
|
+
if (this.isRandom) {
|
|
434
|
+
// 设置按钮文字
|
|
435
|
+
btn_txt = res.can_take === "Y" ? "开心领取" : "去查看";
|
|
436
|
+
}
|
|
437
|
+
// 设置按钮文字
|
|
438
|
+
this.btn_txt = btn_txt;
|
|
439
|
+
}
|
|
254
440
|
|
|
255
|
-
|
|
256
|
-
res.list
|
|
257
|
-
|
|
258
|
-
res.list.map((item) => {
|
|
259
|
-
let mapArr = {"Y": "去查看", "P": "领取", "N": "已发完"}
|
|
441
|
+
if (res.list && res.list.length) {
|
|
442
|
+
this.couponList = res.list.map((item) => {
|
|
443
|
+
let mapArr = { Y: "去查看", P: "领取", N: "已发完" };
|
|
260
444
|
item.btn_txt = mapArr[item.can_take_num];
|
|
261
445
|
if (item.can_take_num === "Y" || item.can_take_num === "P") {
|
|
262
446
|
//按钮样式
|
|
263
447
|
item.btn = res.app_coupon_button_bg_url
|
|
264
448
|
? {
|
|
265
449
|
backgroundImage: `url(${getServiceUrl(
|
|
266
|
-
item.can_take_num === "Y"
|
|
450
|
+
item.can_take_num === "Y"
|
|
451
|
+
? res.app_coupon_button_see_url
|
|
452
|
+
: res.app_coupon_button_bg_url
|
|
267
453
|
)})`,
|
|
268
454
|
backgroundSize: "100% 100%",
|
|
269
455
|
backgroundRepeat: "no-repeat",
|
|
270
|
-
backgroundColor:
|
|
456
|
+
backgroundColor: "",
|
|
271
457
|
margin: "0",
|
|
272
458
|
}
|
|
273
459
|
: {
|
|
274
|
-
backgroundColor:
|
|
460
|
+
backgroundColor: "#FB5B3F",
|
|
275
461
|
margin: "0",
|
|
276
462
|
};
|
|
277
463
|
//整块背景
|
|
@@ -282,34 +468,39 @@ export default {
|
|
|
282
468
|
backgroundRepeat: "no-repeat",
|
|
283
469
|
};
|
|
284
470
|
//icon
|
|
285
|
-
item.icon=
|
|
471
|
+
item.icon =
|
|
472
|
+
item.can_take_num === "Y" ? "iconyilingqu" : "icondailingqu";
|
|
286
473
|
//icon颜色
|
|
287
|
-
item.iconColor =
|
|
474
|
+
item.iconColor =
|
|
475
|
+
item.can_take_num === "Y" ? "#D6D6D6" : this.iconColor;
|
|
288
476
|
//券名称颜色
|
|
289
|
-
item.nameColor =
|
|
477
|
+
item.nameColor = "#FB5B3F";
|
|
290
478
|
//其他文字颜色
|
|
291
|
-
item.infoColor =
|
|
479
|
+
item.infoColor = "#fff";
|
|
292
480
|
} else {
|
|
293
481
|
//按钮样式
|
|
294
482
|
item.btn = { background: "#D6D6D6", margin: "0" };
|
|
295
483
|
//整块背景
|
|
296
|
-
item.headIcon = getServiceUrl(res.app_coupon_invalid_url)
|
|
484
|
+
item.headIcon = getServiceUrl(res.app_coupon_invalid_url);
|
|
297
485
|
item.couponBackground = {
|
|
298
|
-
backgroundImage: `url(${getServiceUrl(
|
|
486
|
+
backgroundImage: `url(${getServiceUrl(
|
|
487
|
+
res.app_coupon_invalid_url
|
|
488
|
+
)})`,
|
|
299
489
|
backgroundSize: "100%",
|
|
300
490
|
backgroundRepeat: "no-repeat",
|
|
301
491
|
};
|
|
302
492
|
//icon
|
|
303
|
-
item.icon=
|
|
493
|
+
item.icon = "iconyifawan";
|
|
304
494
|
//icon颜色
|
|
305
|
-
item.iconColor =
|
|
495
|
+
item.iconColor = "#D6D6D6";
|
|
306
496
|
//券名称颜色
|
|
307
|
-
item.nameColor =
|
|
497
|
+
item.nameColor = "#BBBBBB";
|
|
308
498
|
//其他文字颜色
|
|
309
|
-
item.infoColor =
|
|
499
|
+
item.infoColor = "#BBBBBB";
|
|
310
500
|
}
|
|
311
501
|
return item;
|
|
312
502
|
});
|
|
503
|
+
}
|
|
313
504
|
console.log("couponList", this.couponList);
|
|
314
505
|
this.message = res.message;
|
|
315
506
|
this.notice = res.about;
|
|
@@ -320,19 +511,19 @@ export default {
|
|
|
320
511
|
});
|
|
321
512
|
},
|
|
322
513
|
|
|
323
|
-
toCoupon(){
|
|
514
|
+
toCoupon() {
|
|
324
515
|
this.$xdUniHelper.navigateTo({
|
|
325
516
|
url: this.next_url || this.collectedPath,
|
|
326
517
|
});
|
|
327
518
|
},
|
|
328
519
|
|
|
329
520
|
getCoupont(item) {
|
|
330
|
-
if(item.can_take_num === "Y") {
|
|
521
|
+
if (item.can_take_num === "Y") {
|
|
331
522
|
this.toCoupon();
|
|
332
523
|
return;
|
|
333
524
|
}
|
|
334
525
|
this.$xdShowLoading({});
|
|
335
|
-
jfbRootExec("
|
|
526
|
+
jfbRootExec("getOnceCoupon", {
|
|
336
527
|
vm: this,
|
|
337
528
|
data: {
|
|
338
529
|
...this.options,
|
|
@@ -355,9 +546,42 @@ export default {
|
|
|
355
546
|
return;
|
|
356
547
|
}
|
|
357
548
|
this.order_num = res.tmp_order_number;
|
|
358
|
-
setTimeout(()=>{
|
|
549
|
+
setTimeout(() => {
|
|
550
|
+
this.getResult();
|
|
551
|
+
}, 1000);
|
|
552
|
+
})
|
|
553
|
+
.catch((err) => {
|
|
554
|
+
console.log(err, "err");
|
|
555
|
+
});
|
|
556
|
+
},
|
|
557
|
+
|
|
558
|
+
getAllCoupont() {
|
|
559
|
+
this.$xdShowLoading({});
|
|
560
|
+
jfbRootExec("getAllCoupon", {
|
|
561
|
+
vm: this,
|
|
562
|
+
data: {
|
|
563
|
+
...this.options,
|
|
564
|
+
distribution_method: this.method,
|
|
565
|
+
namespace: this.pageBusinessCode,
|
|
566
|
+
activity_id: this.activity_id,
|
|
567
|
+
},
|
|
568
|
+
})
|
|
569
|
+
.then((res) => {
|
|
570
|
+
if (res.code == 400) {
|
|
571
|
+
this.$xdHideLoading();
|
|
572
|
+
this.$xdAlert({
|
|
573
|
+
content: res.message,
|
|
574
|
+
zIndex: 3200,
|
|
575
|
+
time: 2000,
|
|
576
|
+
isClose: false,
|
|
577
|
+
});
|
|
578
|
+
this.getList();
|
|
579
|
+
return;
|
|
580
|
+
}
|
|
581
|
+
this.order_num = res.tmp_order_number;
|
|
582
|
+
setTimeout(() => {
|
|
359
583
|
this.getResult();
|
|
360
|
-
},1000)
|
|
584
|
+
}, 1000);
|
|
361
585
|
})
|
|
362
586
|
.catch((err) => {
|
|
363
587
|
console.log(err, "err");
|
|
@@ -383,6 +607,7 @@ export default {
|
|
|
383
607
|
isClose: false,
|
|
384
608
|
});
|
|
385
609
|
this.getList();
|
|
610
|
+
this.btn_txt = "去查看";
|
|
386
611
|
if (this.timeer) {
|
|
387
612
|
this.time = 0;
|
|
388
613
|
clearTimeout(this.timeer);
|
|
@@ -415,6 +640,7 @@ export default {
|
|
|
415
640
|
`pay_${res.status_type}`
|
|
416
641
|
);
|
|
417
642
|
}
|
|
643
|
+
this.btn_txt = `领取中 ${res.success_num}/${res.total_num}`;
|
|
418
644
|
this.time++;
|
|
419
645
|
}, Math.pow(this.date, this.time > this.maxTime ? this.maxTime : this.time) * 1000);
|
|
420
646
|
})
|
|
@@ -470,7 +696,7 @@ export default {
|
|
|
470
696
|
overflow-y: auto;
|
|
471
697
|
padding-top: 220rpx;
|
|
472
698
|
box-sizing: border-box;
|
|
473
|
-
background-color: #
|
|
699
|
+
background-color: #fafafa;
|
|
474
700
|
}
|
|
475
701
|
|
|
476
702
|
.empty_data {
|
|
@@ -531,40 +757,39 @@ export default {
|
|
|
531
757
|
margin: unit(20, rpx) auto 0 auto;
|
|
532
758
|
position: relative;
|
|
533
759
|
|
|
534
|
-
&.status_N{
|
|
535
|
-
.item_head{
|
|
536
|
-
color: #
|
|
760
|
+
&.status_N {
|
|
761
|
+
.item_head {
|
|
762
|
+
color: #bbbbbb;
|
|
537
763
|
}
|
|
538
|
-
.item_sub{
|
|
539
|
-
color: #
|
|
764
|
+
.item_sub {
|
|
765
|
+
color: #bbbbbb;
|
|
540
766
|
}
|
|
541
767
|
}
|
|
542
|
-
.btn_wrap{
|
|
768
|
+
.btn_wrap {
|
|
543
769
|
position: absolute;
|
|
544
770
|
right: 30rpx;
|
|
545
771
|
bottom: 40rpx;
|
|
546
772
|
}
|
|
547
773
|
|
|
548
|
-
.item_head{
|
|
774
|
+
.item_head {
|
|
549
775
|
display: flex;
|
|
550
776
|
align-items: center;
|
|
551
777
|
font-size: 40rpx;
|
|
552
778
|
color: #000000;
|
|
553
779
|
font-weight: 500;
|
|
554
780
|
|
|
555
|
-
.t_icon{
|
|
781
|
+
.t_icon {
|
|
556
782
|
width: 44rpx;
|
|
557
783
|
margin-right: 20rpx;
|
|
558
784
|
max-height: 80rpx;
|
|
559
785
|
}
|
|
560
786
|
}
|
|
561
|
-
.item_sub{
|
|
787
|
+
.item_sub {
|
|
562
788
|
margin-top: 26rpx;
|
|
563
|
-
color: #
|
|
789
|
+
color: #ff4d4a;
|
|
564
790
|
font-size: 36rpx;
|
|
565
791
|
font-weight: 400;
|
|
566
792
|
}
|
|
567
|
-
|
|
568
793
|
}
|
|
569
794
|
}
|
|
570
795
|
&-foot {
|
|
@@ -579,7 +579,7 @@
|
|
|
579
579
|
</view>
|
|
580
580
|
</view>
|
|
581
581
|
<view
|
|
582
|
-
v-if="info.pay_info && (biz_code !== 'gift' || info.is_show_gift_price)
|
|
582
|
+
v-if="info.pay_info && (biz_code !== 'gift' || info.is_show_gift_price)"
|
|
583
583
|
class="jfb-base-order-detail__body-card"
|
|
584
584
|
:style="{
|
|
585
585
|
background: backgroundColor,
|
|
@@ -824,7 +824,6 @@ export default {
|
|
|
824
824
|
viewStatus: "", //业务类型预览
|
|
825
825
|
isPreview: false, //是否预览
|
|
826
826
|
biz_code: "",
|
|
827
|
-
is_not_show_price: "",
|
|
828
827
|
|
|
829
828
|
showPassword: false,
|
|
830
829
|
dialogPassword: "",
|
|
@@ -940,7 +939,6 @@ export default {
|
|
|
940
939
|
})
|
|
941
940
|
.then((res) => {
|
|
942
941
|
this.biz_code = res.biz_code;
|
|
943
|
-
this.is_not_show_price = res.is_not_show_price;
|
|
944
942
|
if (this.isPreview) {
|
|
945
943
|
switch (this.viewStatus) {
|
|
946
944
|
case "mall":
|
|
@@ -149,7 +149,7 @@
|
|
|
149
149
|
</view>
|
|
150
150
|
<view class="jfb-base-order-list__body-order-item-bottom">
|
|
151
151
|
<view>下单时间:{{ item.created_time_text }}</view>
|
|
152
|
-
<view v-if="item.biz_code !== 'gift'
|
|
152
|
+
<view v-if="item.biz_code !== 'gift'">
|
|
153
153
|
<text>合计:</text>
|
|
154
154
|
<xd-unit
|
|
155
155
|
:isOld="false"
|