jufubao-base 1.0.105-beta9 → 1.0.105
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/JfbBaseCardInfo/JfbBaseCardInfo.vue +18 -37
- package/src/components/JfbBaseCardInfoEntry/JfbBaseCardInfoEntry.vue +17 -37
- package/src/components/JfbBaseConDialog/Api.js +0 -35
- package/src/components/JfbBaseConDialog/Attr.js +0 -13
- package/src/components/JfbBaseConDialog/JfbBaseConDialog.vue +6 -160
- package/src/components/JfbBaseConList/Attr.js +0 -11
- package/src/components/JfbBaseConList/JfbBaseConList.vue +19 -44
- package/src/components/JfbBaseConList/Mock.js +5 -19
- package/src/components/JfbBasePoster/Attr.js +48 -37
- package/src/components/JfbBasePoster/JfbBasePoster.vue +30 -20
- package/src/components/JfbBasePoster/MoreScreen.vue +9 -4
- package/src/components/JfbBaseSuccess/JfbBaseSuccess.vue +1 -4
- package/src/components/JfbBaseConDialog/XdCouCardBind.vue +0 -197
package/package.json
CHANGED
|
@@ -106,7 +106,7 @@
|
|
|
106
106
|
|
|
107
107
|
<script>
|
|
108
108
|
import XdFontIcon from "@/components/XdFontIcon/XdFontIcon";
|
|
109
|
-
import { jfbRootExec
|
|
109
|
+
import { jfbRootExec } from "@/utils/xd.event";
|
|
110
110
|
import { Base64 } from "js-base64";
|
|
111
111
|
import JfbBaseCardInfoMixin from "./JfbBaseCardInfoMixin";
|
|
112
112
|
import componentsMixins from "@/mixins/componentsMixins";
|
|
@@ -162,7 +162,6 @@ export default {
|
|
|
162
162
|
|
|
163
163
|
qrcode: "", //二维码
|
|
164
164
|
showForm: true,
|
|
165
|
-
hasCon: "", //是否有优惠券
|
|
166
165
|
|
|
167
166
|
//页面跳转地址
|
|
168
167
|
backUrl: "",
|
|
@@ -175,12 +174,6 @@ export default {
|
|
|
175
174
|
},
|
|
176
175
|
created() {},
|
|
177
176
|
methods: {
|
|
178
|
-
toShowCouponDialog(){
|
|
179
|
-
// jfbRootFnExec(this, 'onCustomEvent')("@showBaseConDialog", {user_card_number: "10001000001133"})
|
|
180
|
-
if(this.info){
|
|
181
|
-
jfbRootFnExec(this, 'onCustomEvent')("@showBaseConDialog", {user_card_number: this.info.card_number})
|
|
182
|
-
}
|
|
183
|
-
},
|
|
184
177
|
handleToLink(path) {
|
|
185
178
|
if (this.qrcode) {
|
|
186
179
|
jfbRootExec("qrCardBind", {
|
|
@@ -190,7 +183,14 @@ export default {
|
|
|
190
183
|
},
|
|
191
184
|
})
|
|
192
185
|
.then((res) => {
|
|
193
|
-
this
|
|
186
|
+
this.$xdAlert({
|
|
187
|
+
content: "绑定成功",
|
|
188
|
+
close: () => {
|
|
189
|
+
this.$xdUniHelper.redirectTo({
|
|
190
|
+
url: this.backUrl,
|
|
191
|
+
});
|
|
192
|
+
},
|
|
193
|
+
});
|
|
194
194
|
})
|
|
195
195
|
.catch();
|
|
196
196
|
} else {
|
|
@@ -202,32 +202,19 @@ export default {
|
|
|
202
202
|
},
|
|
203
203
|
})
|
|
204
204
|
.then((res) => {
|
|
205
|
-
|
|
205
|
+
console.log(this.$xdAlert, "this.$xdAlertfsdfs");
|
|
206
|
+
this.$xdAlert({
|
|
207
|
+
content: "绑定成功",
|
|
208
|
+
close: () => {
|
|
209
|
+
this.$xdUniHelper.redirectTo({
|
|
210
|
+
url: this.backUrl,
|
|
211
|
+
});
|
|
212
|
+
},
|
|
213
|
+
});
|
|
206
214
|
})
|
|
207
215
|
.catch();
|
|
208
216
|
}
|
|
209
217
|
},
|
|
210
|
-
handlerAfterBindCard(){
|
|
211
|
-
if(this.hasCon){
|
|
212
|
-
this.toShowCouponDialog();
|
|
213
|
-
this.$bus.$on("onCloseConDialog",(container_id) => {
|
|
214
|
-
if(container_id === this.hasCon){
|
|
215
|
-
this.$xdUniHelper.redirectTo({
|
|
216
|
-
url: this.backUrl,
|
|
217
|
-
});
|
|
218
|
-
}
|
|
219
|
-
})
|
|
220
|
-
}else{
|
|
221
|
-
this.$xdAlert({
|
|
222
|
-
content: "票券绑定成功",
|
|
223
|
-
close: () => {
|
|
224
|
-
this.$xdUniHelper.redirectTo({
|
|
225
|
-
url: this.backUrl,
|
|
226
|
-
});
|
|
227
|
-
},
|
|
228
|
-
});
|
|
229
|
-
}
|
|
230
|
-
},
|
|
231
218
|
init() {
|
|
232
219
|
this.backUrl = getContainerPropsValue(
|
|
233
220
|
this.container,
|
|
@@ -340,12 +327,6 @@ export default {
|
|
|
340
327
|
onJfbShow(options) {
|
|
341
328
|
this.onJfbLoad(options);
|
|
342
329
|
},
|
|
343
|
-
onJfbCustomEvent({action, data}){
|
|
344
|
-
if(action === 'baseConDialog@hasCon'){
|
|
345
|
-
this.hasCon = data;
|
|
346
|
-
}
|
|
347
|
-
console.log('onJfbCustomEvent',action, data);
|
|
348
|
-
}
|
|
349
330
|
},
|
|
350
331
|
};
|
|
351
332
|
</script>
|
|
@@ -124,7 +124,7 @@
|
|
|
124
124
|
|
|
125
125
|
<script>
|
|
126
126
|
import XdFontIcon from "@/components/XdFontIcon/XdFontIcon";
|
|
127
|
-
import { jfbRootExec
|
|
127
|
+
import { jfbRootExec } from "@/utils/xd.event";
|
|
128
128
|
import JfbBaseCardInfoEntryMixin from "./JfbBaseCardInfoEntryMixin";
|
|
129
129
|
import { getContainerPropsValue } from "@/utils/xd.base";
|
|
130
130
|
import getServiceUrl from "@/common/getServiceUrl";
|
|
@@ -157,7 +157,6 @@ export default {
|
|
|
157
157
|
|
|
158
158
|
qrcode: "", //二维码
|
|
159
159
|
showForm: true,
|
|
160
|
-
hasCon: "",
|
|
161
160
|
|
|
162
161
|
//页面跳转地址
|
|
163
162
|
backUrl: "",
|
|
@@ -176,12 +175,6 @@ export default {
|
|
|
176
175
|
},
|
|
177
176
|
created() {},
|
|
178
177
|
methods: {
|
|
179
|
-
toShowCouponDialog(){
|
|
180
|
-
// jfbRootFnExec(this, 'onCustomEvent')("@showBaseConDialog", {user_card_number: "10001000001133"})
|
|
181
|
-
if(this.info){
|
|
182
|
-
jfbRootFnExec(this, 'onCustomEvent')("@showBaseConDialog", {user_card_number: this.info.card_number})
|
|
183
|
-
}
|
|
184
|
-
},
|
|
185
178
|
handleToLink() {
|
|
186
179
|
if(this.info.card_point===0) {
|
|
187
180
|
this.$xdConfirm({
|
|
@@ -207,7 +200,14 @@ export default {
|
|
|
207
200
|
},
|
|
208
201
|
})
|
|
209
202
|
.then((res) => {
|
|
210
|
-
this
|
|
203
|
+
this.$xdAlert({
|
|
204
|
+
content: "票券绑定成功",
|
|
205
|
+
close: () => {
|
|
206
|
+
this.$xdUniHelper.redirectTo({
|
|
207
|
+
url: this.backUrl,
|
|
208
|
+
});
|
|
209
|
+
},
|
|
210
|
+
});
|
|
211
211
|
})
|
|
212
212
|
.catch();
|
|
213
213
|
} else {
|
|
@@ -221,32 +221,18 @@ export default {
|
|
|
221
221
|
})
|
|
222
222
|
.then((res) => {
|
|
223
223
|
console.log(this.$xdAlert, "this.$xdAlertfsdfs");
|
|
224
|
-
this
|
|
224
|
+
this.$xdAlert({
|
|
225
|
+
content: "票券绑定成功",
|
|
226
|
+
close: () => {
|
|
227
|
+
this.$xdUniHelper.redirectTo({
|
|
228
|
+
url: this.backUrl,
|
|
229
|
+
});
|
|
230
|
+
},
|
|
231
|
+
});
|
|
225
232
|
})
|
|
226
233
|
.catch();
|
|
227
234
|
}
|
|
228
235
|
},
|
|
229
|
-
handlerAfterBindCard(){
|
|
230
|
-
if(this.hasCon){
|
|
231
|
-
this.toShowCouponDialog();
|
|
232
|
-
this.$bus.$on("onCloseConDialog",(container_id) => {
|
|
233
|
-
if(container_id === this.hasCon){
|
|
234
|
-
this.$xdUniHelper.redirectTo({
|
|
235
|
-
url: this.backUrl,
|
|
236
|
-
});
|
|
237
|
-
}
|
|
238
|
-
})
|
|
239
|
-
}else{
|
|
240
|
-
this.$xdAlert({
|
|
241
|
-
content: "票券绑定成功",
|
|
242
|
-
close: () => {
|
|
243
|
-
this.$xdUniHelper.redirectTo({
|
|
244
|
-
url: this.backUrl,
|
|
245
|
-
});
|
|
246
|
-
},
|
|
247
|
-
});
|
|
248
|
-
}
|
|
249
|
-
},
|
|
250
236
|
init() {
|
|
251
237
|
this.backUrl = getContainerPropsValue(
|
|
252
238
|
this.container,
|
|
@@ -376,12 +362,6 @@ export default {
|
|
|
376
362
|
onJfbShow(options) {
|
|
377
363
|
this.onJfbLoad(options);
|
|
378
364
|
},
|
|
379
|
-
onJfbCustomEvent({action, data}){
|
|
380
|
-
if(action === 'baseConDialog@hasCon'){
|
|
381
|
-
this.hasCon = data;
|
|
382
|
-
}
|
|
383
|
-
console.log('onJfbCustomEvent',action, data);
|
|
384
|
-
}
|
|
385
365
|
},
|
|
386
366
|
};
|
|
387
367
|
</script>
|
|
@@ -16,39 +16,4 @@ module.exports = [
|
|
|
16
16
|
isConsole: true,
|
|
17
17
|
disabled: true,
|
|
18
18
|
},
|
|
19
|
-
{
|
|
20
|
-
mapFnName: 'getCouponList', //自定义方法名字(必选)
|
|
21
|
-
title: '获取优惠券列表',
|
|
22
|
-
path: '/sms-coupon/v1/activity-prizes-user/list',
|
|
23
|
-
isRule: false,
|
|
24
|
-
params: {
|
|
25
|
-
distribution_method: ['发放方式 entry=主动发放, homed=首页发放,paid=消费后发放,card_binded=绑定卡后发放', 'String', '选填'],
|
|
26
|
-
namespace: ['业务线', 'String', '必填'],
|
|
27
|
-
},
|
|
28
|
-
isConsole: true,
|
|
29
|
-
disabled: true,
|
|
30
|
-
},
|
|
31
|
-
{
|
|
32
|
-
mapFnName: 'getAllCoupon', //自定义方法名字(必选)
|
|
33
|
-
title: '领取优惠券',
|
|
34
|
-
path: '/sms-coupon/v1/activity-prizes-user/set',
|
|
35
|
-
isRule: false,
|
|
36
|
-
params: {
|
|
37
|
-
distribution_method: ['发放方式 entry=主动发放, homed=首页发放,paid=消费后发放,card_binded=绑定卡后发放', 'String', '选填'],
|
|
38
|
-
namespace: ['业务线', 'String', '必填'],
|
|
39
|
-
},
|
|
40
|
-
isConsole: true,
|
|
41
|
-
disabled: true,
|
|
42
|
-
},
|
|
43
|
-
{
|
|
44
|
-
mapFnName: 'getCouponResult', //自定义方法名字(必选)
|
|
45
|
-
title: '轮询查询活动结果',
|
|
46
|
-
path: '/sms-coupon/v1/activity-prizes-user/get',
|
|
47
|
-
isRule: false,
|
|
48
|
-
params: {
|
|
49
|
-
tmp_order_number: ['tmp_order_number', 'String', '选填'],
|
|
50
|
-
},
|
|
51
|
-
isConsole: true,
|
|
52
|
-
disabled: true,
|
|
53
|
-
},
|
|
54
19
|
];
|
|
@@ -31,19 +31,6 @@ export default {
|
|
|
31
31
|
{ label: '切换', value: 2 },
|
|
32
32
|
]
|
|
33
33
|
},
|
|
34
|
-
{
|
|
35
|
-
label: "触发事件:",
|
|
36
|
-
ele: "xd-select-list",
|
|
37
|
-
valueKey: "distribution_method",
|
|
38
|
-
value: data.distribution_method || "",
|
|
39
|
-
placeholder: "请选择触发事件",
|
|
40
|
-
className: 'input80',
|
|
41
|
-
list: [
|
|
42
|
-
{ label: "首页发放", value: "homed" },
|
|
43
|
-
{ label: "支付成功", value: "paid" },
|
|
44
|
-
{ label: "绑卡成功", value: "card_binded" },
|
|
45
|
-
]
|
|
46
|
-
},
|
|
47
34
|
{
|
|
48
35
|
label: '弹窗间隔:',
|
|
49
36
|
ele: 'el-input',
|
|
@@ -17,9 +17,9 @@
|
|
|
17
17
|
</view>
|
|
18
18
|
<!-- #endif -->
|
|
19
19
|
<view class="jfb-base-con-dialog__body">
|
|
20
|
-
<view
|
|
20
|
+
<view class="jfb-base-con-dialog__body-dialog" v-if="isShow">
|
|
21
21
|
<view class="jfb-base-con-dialog__body-dialog-mask"></view>
|
|
22
|
-
<view
|
|
22
|
+
<view class="jfb-base-con-dialog__body-dialog-content">
|
|
23
23
|
<view v-if="list.length>1" class="jfb-base-con-dialog__body-dialog-content-num">
|
|
24
24
|
<text>{{ currentIndex + 1 }}/{{ list.length }}</text>
|
|
25
25
|
</view>
|
|
@@ -51,16 +51,7 @@
|
|
|
51
51
|
size="64"
|
|
52
52
|
></xd-font-icon>
|
|
53
53
|
</view>
|
|
54
|
-
<view v-else class="jfb-base-con-dialog__body-dialog-content">
|
|
55
|
-
<xd-cou-card-bind
|
|
56
|
-
:list="couponList"
|
|
57
|
-
:setting="couponOther"
|
|
58
|
-
@closeDialog="handleCardBindClose"
|
|
59
|
-
@getCoupont="handleGetCoupon"
|
|
60
|
-
></xd-cou-card-bind>
|
|
61
|
-
</view>
|
|
62
54
|
</view>
|
|
63
|
-
|
|
64
55
|
<view
|
|
65
56
|
:style="{ background: backgroundColor, color: warningColor }"
|
|
66
57
|
class="jfb-base-con-dialog__body-pop"
|
|
@@ -73,7 +64,7 @@
|
|
|
73
64
|
|
|
74
65
|
<script>
|
|
75
66
|
import XdFontIcon from "@/components/XdFontIcon/XdFontIcon";
|
|
76
|
-
import { jfbRootExec, JfbEvent
|
|
67
|
+
import { jfbRootExec, JfbEvent } from "@/utils/xd.event";
|
|
77
68
|
import JfbBaseConDialogMixin from "./JfbBaseConDialogMixin";
|
|
78
69
|
import componentsMixins from "@/mixins/componentsMixins";
|
|
79
70
|
import extsMixins from "@/mixins/extsMixins";
|
|
@@ -83,13 +74,11 @@ import colorCardMixins from "@/mixins/colorCardMixins";
|
|
|
83
74
|
const Color = require("color");
|
|
84
75
|
import { mapState } from "vuex";
|
|
85
76
|
import storage from "@/common/storage";
|
|
86
|
-
import XdCouCardBind from "./XdCouCardBind";
|
|
87
77
|
|
|
88
78
|
export default {
|
|
89
79
|
name: "JfbBaseConDialog",
|
|
90
80
|
components: {
|
|
91
81
|
XdFontIcon,
|
|
92
|
-
XdCouCardBind
|
|
93
82
|
},
|
|
94
83
|
mixins: [componentsMixins, extsMixins, JfbBaseConDialogMixin],
|
|
95
84
|
data() {
|
|
@@ -104,15 +93,6 @@ export default {
|
|
|
104
93
|
isPreview: false, //是否预览
|
|
105
94
|
activity_id: "",
|
|
106
95
|
backgroundColor: "",
|
|
107
|
-
distribution_method: "homed", //触发事件
|
|
108
|
-
dispatchData: "", //触发事件参数
|
|
109
|
-
|
|
110
|
-
couponList: [],
|
|
111
|
-
couponOther: {},
|
|
112
|
-
order_num: null,
|
|
113
|
-
timer: null,
|
|
114
|
-
timeNum: 0,
|
|
115
|
-
|
|
116
96
|
};
|
|
117
97
|
},
|
|
118
98
|
computed: {
|
|
@@ -134,7 +114,6 @@ export default {
|
|
|
134
114
|
this.list_url = getContainerPropsValue(value, "content.list_url", {
|
|
135
115
|
value: "",
|
|
136
116
|
}).value;
|
|
137
|
-
this.distribution_method = getContainerPropsValue(value, "content.distribution_method", "homed");
|
|
138
117
|
this.type = getContainerPropsValue(value, "content.type", 1);
|
|
139
118
|
this.isHide = getContainerPropsValue(value, "content.isHide", false);
|
|
140
119
|
this.time = Number(getContainerPropsValue(value, "content.time", 3));
|
|
@@ -142,106 +121,16 @@ export default {
|
|
|
142
121
|
this.isShow = !this.isHide;
|
|
143
122
|
}
|
|
144
123
|
},
|
|
145
|
-
|
|
146
|
-
handleGetCoupon(item){
|
|
147
|
-
this.$xdShowLoading({});
|
|
148
|
-
jfbRootExec("getAllCoupon", {
|
|
149
|
-
vm: this,
|
|
150
|
-
data: {
|
|
151
|
-
prize_id: item.prize_id,
|
|
152
|
-
distribution_method: this.distribution_method,
|
|
153
|
-
...this.dispatchData
|
|
154
|
-
}
|
|
155
|
-
}).then(res => {
|
|
156
|
-
if (res.code == 400) {
|
|
157
|
-
this.$xdHideLoading();
|
|
158
|
-
this.$xdAlert({
|
|
159
|
-
content: res.message,
|
|
160
|
-
zIndex: 3200,
|
|
161
|
-
time: 2000,
|
|
162
|
-
isClose: false,
|
|
163
|
-
});
|
|
164
|
-
this.getDialogList();
|
|
165
|
-
return;
|
|
166
|
-
}
|
|
167
|
-
this.order_num = res.tmp_order_number;
|
|
168
|
-
setTimeout(()=>{
|
|
169
|
-
this.getResult();
|
|
170
|
-
},1000)
|
|
171
|
-
}).catch((err) => {
|
|
172
|
-
console.log(err, "err");
|
|
173
|
-
});
|
|
174
|
-
},
|
|
175
|
-
getResult() {
|
|
176
|
-
jfbRootExec("getCouponResult", {
|
|
177
|
-
vm: this,
|
|
178
|
-
data: {
|
|
179
|
-
tmp_order_number: this.order_num,
|
|
180
|
-
},
|
|
181
|
-
})
|
|
182
|
-
.then((res) => {
|
|
183
|
-
if (res.status_type === "success") {
|
|
184
|
-
this.order_num = null;
|
|
185
|
-
this.$xdHideLoading();
|
|
186
|
-
this.$xdAlert({
|
|
187
|
-
content: "领取成功",
|
|
188
|
-
zIndex: 3200,
|
|
189
|
-
time: 2000,
|
|
190
|
-
isClose: false,
|
|
191
|
-
});
|
|
192
|
-
this.getDialogList();
|
|
193
|
-
if (this.timer) {
|
|
194
|
-
this.timeNum = 0;
|
|
195
|
-
clearTimeout(this.timer);
|
|
196
|
-
}
|
|
197
|
-
return;
|
|
198
|
-
}
|
|
199
|
-
if (res.status_type === "error") {
|
|
200
|
-
this.$xdHideLoading();
|
|
201
|
-
this.$xdAlert({
|
|
202
|
-
content: res.message,
|
|
203
|
-
zIndex: 3200,
|
|
204
|
-
time: 2000,
|
|
205
|
-
isClose: false,
|
|
206
|
-
});
|
|
207
|
-
if (res.code == 400) {
|
|
208
|
-
this.getDialogList();
|
|
209
|
-
}
|
|
210
|
-
if (this.timer) {
|
|
211
|
-
this.timeNum = 0;
|
|
212
|
-
clearTimeout(this.timer);
|
|
213
|
-
}
|
|
214
|
-
return;
|
|
215
|
-
}
|
|
216
|
-
|
|
217
|
-
this.timer = setTimeout(() => {
|
|
218
|
-
this.getResult();
|
|
219
|
-
if (this.timeNum > 5) {
|
|
220
|
-
this.$xdLog.setARMSInfo(
|
|
221
|
-
{ message: "领取中" },
|
|
222
|
-
`pay_${res.status_type}`
|
|
223
|
-
);
|
|
224
|
-
}
|
|
225
|
-
this.timeNum++;
|
|
226
|
-
}, Math.pow(2, this.timeNum > 5 ? 5 : this.timeNum) * 1000);
|
|
227
|
-
})
|
|
228
|
-
.catch((err) => {
|
|
229
|
-
this.$xdHideLoading();
|
|
230
|
-
console.log(err, "err");
|
|
231
|
-
});
|
|
232
|
-
},
|
|
233
|
-
p_getDialogList(){
|
|
124
|
+
getDialogList() {
|
|
234
125
|
jfbRootExec("getCouponDialogList", {
|
|
235
126
|
vm: this,
|
|
236
127
|
data: {
|
|
237
128
|
namespace: this.pageBusinessCode,
|
|
238
|
-
distribution_method: this.distribution_method,
|
|
239
129
|
},
|
|
240
130
|
})
|
|
241
131
|
.then((res) => {
|
|
242
132
|
console.log(res, "resresres");
|
|
243
133
|
this.list = res.list;
|
|
244
|
-
if(res.list.length === 0) return;
|
|
245
134
|
this.currentImage = getServiceUrl(
|
|
246
135
|
this.list[this.currentIndex].app_activity_url
|
|
247
136
|
);
|
|
@@ -255,31 +144,6 @@ export default {
|
|
|
255
144
|
console.log(err, "err");
|
|
256
145
|
});
|
|
257
146
|
},
|
|
258
|
-
p_getCouponList(){
|
|
259
|
-
jfbRootExec("getCouponList", {
|
|
260
|
-
vm: this,
|
|
261
|
-
data: {
|
|
262
|
-
distribution_method: this.distribution_method,
|
|
263
|
-
...this.dispatchData
|
|
264
|
-
}
|
|
265
|
-
}).then(res => {
|
|
266
|
-
const { list, ...other } = res;
|
|
267
|
-
this.couponList = list;
|
|
268
|
-
this.couponOther = other;
|
|
269
|
-
if(res.can_take === "Y" && res.has_times === "Y" && list.length > 0){
|
|
270
|
-
this.isShow = true;
|
|
271
|
-
}else{
|
|
272
|
-
this.handleCardBindClose();
|
|
273
|
-
}
|
|
274
|
-
})
|
|
275
|
-
},
|
|
276
|
-
getDialogList() {
|
|
277
|
-
if(this.distribution_method === 'card_binded'){
|
|
278
|
-
this.p_getCouponList();
|
|
279
|
-
}else{
|
|
280
|
-
this.p_getDialogList();
|
|
281
|
-
}
|
|
282
|
-
},
|
|
283
147
|
handlePop() {
|
|
284
148
|
console.log("this.time", this.time * 60 + "分钟");
|
|
285
149
|
storage.set(this.containerId, 1, this.time);
|
|
@@ -287,23 +151,12 @@ export default {
|
|
|
287
151
|
},
|
|
288
152
|
onJfbLoad(options) {
|
|
289
153
|
console.log(11111);
|
|
290
|
-
//支付跟绑卡是主动触发
|
|
291
154
|
try {
|
|
292
|
-
if (!storage.get(this.containerId)
|
|
293
|
-
this.distribution_method !== "paid" &&
|
|
294
|
-
this.distribution_method !== "card_binded") this.getDialogList();
|
|
155
|
+
if (!storage.get(this.containerId)) this.getDialogList();
|
|
295
156
|
} catch (error) {
|
|
296
157
|
console.log(error, "errorerror");
|
|
297
158
|
}
|
|
298
|
-
if(this.distribution_method === 'card_binded'){
|
|
299
|
-
jfbRootFnExec(this, 'onCustomEvent')("baseConDialog@hasCon", this.containerId);
|
|
300
|
-
}
|
|
301
|
-
},
|
|
302
|
-
handleCardBindClose(){
|
|
303
|
-
this.isShow = false;
|
|
304
|
-
this.$bus.$emit("onCloseConDialog", this.containerId);
|
|
305
159
|
},
|
|
306
|
-
|
|
307
160
|
onJfbUpdate(data) {
|
|
308
161
|
storage.remove(this.containerId);
|
|
309
162
|
this.getDialogList();
|
|
@@ -314,7 +167,7 @@ export default {
|
|
|
314
167
|
},
|
|
315
168
|
handleToList() {
|
|
316
169
|
this.$xdUniHelper.navigateTo({
|
|
317
|
-
url: `${this.list_url}?activity_id=${this.activity_id}&distribution_method
|
|
170
|
+
url: `${this.list_url}?activity_id=${this.activity_id}&distribution_method=homed`,
|
|
318
171
|
});
|
|
319
172
|
},
|
|
320
173
|
handleClose() {
|
|
@@ -348,13 +201,6 @@ export default {
|
|
|
348
201
|
);
|
|
349
202
|
this.activity_id = this.list[this.currentIndex].activity_id;
|
|
350
203
|
},
|
|
351
|
-
onJfbCustomEvent({action, data}){
|
|
352
|
-
if(action === '@showBaseConDialog'){
|
|
353
|
-
this.dispatchData = data;
|
|
354
|
-
this.getDialogList();
|
|
355
|
-
}
|
|
356
|
-
console.log('onJfbCustomEvent',action, data);
|
|
357
|
-
}
|
|
358
204
|
},
|
|
359
205
|
};
|
|
360
206
|
</script>
|
|
@@ -6,17 +6,6 @@
|
|
|
6
6
|
export default {
|
|
7
7
|
style: [],
|
|
8
8
|
content: [
|
|
9
|
-
{
|
|
10
|
-
label: '查看已领票券路径:', //label
|
|
11
|
-
ele: 'xd-select-pages-path', //package 名称
|
|
12
|
-
valueKey: 'collectedPath', //form[valueKey]
|
|
13
|
-
placeholder: '请选择查看已领票券路径',
|
|
14
|
-
value: null,
|
|
15
|
-
setting: {
|
|
16
|
-
router: XdBus.getParentApi('getPagesTree'),
|
|
17
|
-
},
|
|
18
|
-
inline: false,
|
|
19
|
-
},
|
|
20
9
|
// {
|
|
21
10
|
// label: '领券规则:',
|
|
22
11
|
// ele: 'xd-site-news',
|
|
@@ -16,14 +16,15 @@
|
|
|
16
16
|
<view class="jfb-base-con-list__edit-icon" @click="delEdit">删除</view>
|
|
17
17
|
</view>
|
|
18
18
|
<!-- #endif -->
|
|
19
|
-
<view class="jfb-base-con-list__body" v-if="done"
|
|
20
|
-
backgroundImage: `url(${background})`,
|
|
21
|
-
backgroundSize: '100%',
|
|
22
|
-
backgroundRepeat: 'no-repeat',
|
|
23
|
-
minHeight: `${layoutInfo.bodyMinHeightRpx}rpx`,
|
|
24
|
-
}">
|
|
19
|
+
<view class="jfb-base-con-list__body" v-if="done">
|
|
25
20
|
<view
|
|
26
21
|
v-if="couponList&&couponList.length > 0"
|
|
22
|
+
:style="{
|
|
23
|
+
backgroundImage: `url(${background})`,
|
|
24
|
+
backgroundSize: '100%',
|
|
25
|
+
backgroundRepeat: 'no-repeat',
|
|
26
|
+
height: `${layoutInfo.bodyMinHeightRpx}rpx`,
|
|
27
|
+
}"
|
|
27
28
|
>
|
|
28
29
|
<view class="jfb-base-con-list__body-content">
|
|
29
30
|
<view class="jfb-base-con-list__body-content-header">
|
|
@@ -40,7 +41,7 @@
|
|
|
40
41
|
<xd-font-icon size="20" icon="iconxiangyou_xian"></xd-font-icon>
|
|
41
42
|
</view>
|
|
42
43
|
</view>
|
|
43
|
-
<view
|
|
44
|
+
<view class="jfb-base-con-list__body-content-list">
|
|
44
45
|
<view v-for="(item, index) in couponList" :key="index">
|
|
45
46
|
<view
|
|
46
47
|
class="jfb-base-con-list__body-content-list-item"
|
|
@@ -105,27 +106,24 @@
|
|
|
105
106
|
<view></view>
|
|
106
107
|
|
|
107
108
|
<xd-button
|
|
109
|
+
v-if="item.can_take_num !== 'Y'"
|
|
108
110
|
size="small"
|
|
109
|
-
:disabled="item.
|
|
111
|
+
:disabled="item.remain_card_count == 0"
|
|
110
112
|
@click="getCoupont(item)"
|
|
111
113
|
type="primary"
|
|
112
|
-
style="width: 170rpx;height: 60rpx;"
|
|
113
114
|
:style="item.btn"
|
|
114
115
|
:color="item.infoColor"
|
|
115
|
-
|
|
116
|
+
>领取</xd-button
|
|
117
|
+
>
|
|
116
118
|
</view>
|
|
117
119
|
</view>
|
|
118
120
|
</view>
|
|
119
121
|
</view>
|
|
120
122
|
</view>
|
|
121
|
-
<view
|
|
122
|
-
|
|
123
|
-
|
|
123
|
+
<view class="jfb-base-con-list__body-content-foot"
|
|
124
|
+
>可在我的-我的票券进行查看</view
|
|
125
|
+
>
|
|
124
126
|
</view>
|
|
125
|
-
<view class="jfb-base-con-list__body-content-foot"
|
|
126
|
-
@click="toCoupon"
|
|
127
|
-
>查看已领票券</view
|
|
128
|
-
>
|
|
129
127
|
</view>
|
|
130
128
|
<view
|
|
131
129
|
v-else
|
|
@@ -182,9 +180,6 @@ export default {
|
|
|
182
180
|
activity_id: "",
|
|
183
181
|
background: "",
|
|
184
182
|
app_coupon_url: "",
|
|
185
|
-
used_up_url: "",
|
|
186
|
-
can_take: "",
|
|
187
|
-
has_times: "",
|
|
188
183
|
method: "entry",
|
|
189
184
|
maxTime: 5, //最长轮询2的N次方(秒)
|
|
190
185
|
date: 2, //时间底数
|
|
@@ -193,8 +188,6 @@ export default {
|
|
|
193
188
|
order_num: null,
|
|
194
189
|
done: false,
|
|
195
190
|
message: "",
|
|
196
|
-
|
|
197
|
-
collectedPath: "",
|
|
198
191
|
};
|
|
199
192
|
},
|
|
200
193
|
computed: {
|
|
@@ -220,7 +213,6 @@ export default {
|
|
|
220
213
|
init(value) {
|
|
221
214
|
this.contentBackground = '#FFF8F8';
|
|
222
215
|
this.iconColor = '#FF4D4A';
|
|
223
|
-
this.collectedPath = getContainerPropsValue(value, "content.collectedPath", {value: ''}).value;
|
|
224
216
|
},
|
|
225
217
|
getList() {
|
|
226
218
|
jfbRootExec("getCouponList", {
|
|
@@ -233,22 +225,16 @@ export default {
|
|
|
233
225
|
})
|
|
234
226
|
.then((res) => {
|
|
235
227
|
this.background = getServiceUrl(res.background);
|
|
236
|
-
this.used_up_url = res.used_up_url && getServiceUrl(res.used_up_url);
|
|
237
|
-
this.can_take = res.can_take;
|
|
238
|
-
this.has_times = res.has_times;
|
|
239
|
-
|
|
240
228
|
this.couponList =
|
|
241
229
|
res.list &&
|
|
242
230
|
res.list.length > 0 &&
|
|
243
231
|
res.list.map((item) => {
|
|
244
|
-
let mapArr = {"Y": "去查看", "P": "领取", "N": "已发完"}
|
|
245
|
-
item.btn_txt = mapArr[item.can_take_num];
|
|
246
232
|
if (item.can_take_num === "Y" || item.can_take_num === "P") {
|
|
247
233
|
//按钮样式
|
|
248
234
|
item.btn = res.app_coupon_button_bg_url
|
|
249
235
|
? {
|
|
250
236
|
backgroundImage: `url(${getServiceUrl(
|
|
251
|
-
|
|
237
|
+
res.app_coupon_button_bg_url
|
|
252
238
|
)})`,
|
|
253
239
|
backgroundSize: "100%",
|
|
254
240
|
backgroundRepeat: "no-repeat",
|
|
@@ -302,16 +288,7 @@ export default {
|
|
|
302
288
|
console.log(err, "err");
|
|
303
289
|
});
|
|
304
290
|
},
|
|
305
|
-
toCoupon(){
|
|
306
|
-
this.$xdUniHelper.navigateTo({
|
|
307
|
-
url: this.collectedPath,
|
|
308
|
-
});
|
|
309
|
-
},
|
|
310
291
|
getCoupont(item) {
|
|
311
|
-
if(item.can_take_num === "Y") {
|
|
312
|
-
this.toCoupon();
|
|
313
|
-
return;
|
|
314
|
-
}
|
|
315
292
|
this.$xdShowLoading({});
|
|
316
293
|
jfbRootExec("getAllCoupon", {
|
|
317
294
|
vm: this,
|
|
@@ -352,7 +329,6 @@ export default {
|
|
|
352
329
|
})
|
|
353
330
|
.then((res) => {
|
|
354
331
|
if (res.status_type === "success") {
|
|
355
|
-
this.order_num = null;
|
|
356
332
|
this.$xdHideLoading();
|
|
357
333
|
this.$xdAlert({
|
|
358
334
|
content: "领取成功",
|
|
@@ -462,9 +438,6 @@ export default {
|
|
|
462
438
|
&__body {
|
|
463
439
|
position: relative;
|
|
464
440
|
overflow-y: auto;
|
|
465
|
-
padding-top: 82px;
|
|
466
|
-
box-sizing: border-box;
|
|
467
|
-
background-color: #FAFAFA;
|
|
468
441
|
.empty_data {
|
|
469
442
|
text-align: center;
|
|
470
443
|
color: #999999;
|
|
@@ -482,6 +455,8 @@ export default {
|
|
|
482
455
|
border-radius: unit(20, rpx);
|
|
483
456
|
background: #fff;
|
|
484
457
|
padding: unit(34, rpx);
|
|
458
|
+
position: relative;
|
|
459
|
+
top: unit(164, rpx);
|
|
485
460
|
margin-right: auto;
|
|
486
461
|
margin-left: auto;
|
|
487
462
|
width: unit(650, rpx);
|
|
@@ -559,7 +534,7 @@ export default {
|
|
|
559
534
|
color: #a6a6a6;
|
|
560
535
|
font-size: unit(24, rpx);
|
|
561
536
|
text-align: center;
|
|
562
|
-
margin: unit(40, rpx)
|
|
537
|
+
margin-top: unit(40, rpx);
|
|
563
538
|
}
|
|
564
539
|
}
|
|
565
540
|
}
|
|
@@ -1,25 +1,11 @@
|
|
|
1
1
|
'use strict';
|
|
2
2
|
|
|
3
3
|
module.exports = {
|
|
4
|
-
getCouponList: {
|
|
5
|
-
"
|
|
6
|
-
|
|
7
|
-
|
|
8
|
-
|
|
9
|
-
],
|
|
10
|
-
"background":"//sandbox-img.jufubao.cn/uploads/20231204/96b801e0dc27422c183dc90d905dd2ed.jpg",
|
|
11
|
-
"used_up_url": "",
|
|
12
|
-
"has_times": "Y",
|
|
13
|
-
"can_take":"Y",
|
|
14
|
-
"message":"",
|
|
15
|
-
"app_coupon_url":"//sandbox-img.jufubao.cn/uploads/20231205/fee9b644b83495c9ba8a4db277600b54.jpg",
|
|
16
|
-
"app_activity_button":"//sandbox-img.jufubao.cn/uploads/20231207/35f3065b2b2bc3fc2dda73d7b5b9eae8.jpg",
|
|
17
|
-
"app_coupon_button_bg_url":"//sandbox-img.jufubao.cn/uploads/20231212/026a3ea901f87f51b531d06c24604676.png",
|
|
18
|
-
"app_coupon_button_see_url": "//sandbox-img.jufubao.cn/uploads/20231212/026a3ea901f87f51b531d06c24604676.png",
|
|
19
|
-
"app_coupon_invalid_url":"//sandbox-img.jufubao.cn/uploads/20231208/8b153ce4870686a37295c16fbc992235.jpg",
|
|
20
|
-
"rule":"<p>打发·</p>",
|
|
21
|
-
"request_id":"a2603f2a480485f4"
|
|
22
|
-
},
|
|
4
|
+
getCouponList: {"list":[
|
|
5
|
+
{"prize_id":153,"prize_name":"满50减50","prize_type":"满减券","prize_num":1,"can_take":"Y","is_over":"N","can_take_num":"P","today_times":1,"today_num":0,"total_times":1,"total_num":0,"remain_card_count":55},
|
|
6
|
+
{"prize_id":153,"prize_name":"满50减50","prize_type":"满减券","prize_num":1,"can_take":"Y","is_over":"N","can_take_num":"P","today_times":1,"today_num":0,"total_times":1,"total_num":0,"remain_card_count":55},
|
|
7
|
+
{"prize_id":153,"prize_name":"满50减50","prize_type":"满减券","prize_num":1,"can_take":"Y","is_over":"N","can_take_num":"P","today_times":1,"today_num":0,"total_times":1,"total_num":0,"remain_card_count":55}
|
|
8
|
+
],"background":"//sandbox-img.jufubao.cn/uploads/20231204/96b801e0dc27422c183dc90d905dd2ed.jpg","can_take":"Y","message":"","app_coupon_url":"//sandbox-img.jufubao.cn/uploads/20231205/fee9b644b83495c9ba8a4db277600b54.jpg","app_activity_button":"//sandbox-img.jufubao.cn/uploads/20231207/35f3065b2b2bc3fc2dda73d7b5b9eae8.jpg","app_coupon_button_bg_url":"//sandbox-img.jufubao.cn/uploads/20231212/026a3ea901f87f51b531d06c24604676.png","app_coupon_invalid_url":"//sandbox-img.jufubao.cn/uploads/20231208/8b153ce4870686a37295c16fbc992235.jpg","request_id":"a2603f2a480485f4"},
|
|
23
9
|
getAllCoupon: {
|
|
24
10
|
"request_id": "5987aa28c709d4ef"
|
|
25
11
|
}
|
|
@@ -221,27 +221,27 @@ export default {
|
|
|
221
221
|
{required: true, message: '请选择广告位置', trigger: 'change'},
|
|
222
222
|
],
|
|
223
223
|
},
|
|
224
|
-
|
|
225
|
-
|
|
226
|
-
|
|
227
|
-
|
|
228
|
-
|
|
229
|
-
|
|
230
|
-
|
|
231
|
-
|
|
232
|
-
|
|
233
|
-
|
|
234
|
-
|
|
235
|
-
|
|
236
|
-
|
|
237
|
-
|
|
238
|
-
|
|
239
|
-
|
|
240
|
-
|
|
241
|
-
|
|
224
|
+
{
|
|
225
|
+
ele: 'title',
|
|
226
|
+
label: '广告位轮廓设置',
|
|
227
|
+
size: 'small', //default/mini/small
|
|
228
|
+
},
|
|
229
|
+
{
|
|
230
|
+
label: '广告位边距设置:',
|
|
231
|
+
ele: 'xd-margin-padding',
|
|
232
|
+
valueKey: 'margin',
|
|
233
|
+
value: params.margin || null,
|
|
234
|
+
disabled: false,
|
|
235
|
+
setting: {
|
|
236
|
+
type: 'margin',
|
|
237
|
+
},
|
|
238
|
+
placeholder: '请设置广告位边距设置',
|
|
239
|
+
inline: false,
|
|
240
|
+
notice: '设置边距充,<span style="color: red">单位:像素(px)</span>。默认值:<span style="color: red">0</span>像素',
|
|
241
|
+
|
|
242
242
|
},
|
|
243
243
|
params.poster && params.poster['type']&& params.poster['type'] !== '1' &&{
|
|
244
|
-
label: '
|
|
244
|
+
label: '广告位填充设置:',
|
|
245
245
|
ele: 'xd-margin-padding',
|
|
246
246
|
valueKey: 'bgImagePadding',
|
|
247
247
|
value: params['bgImagePadding'] || null,
|
|
@@ -251,17 +251,17 @@ export default {
|
|
|
251
251
|
},
|
|
252
252
|
placeholder: '请填充设置',
|
|
253
253
|
inline: false,
|
|
254
|
-
notice: '设置内填充,<span style="color: red"
|
|
254
|
+
notice: '设置内填充,<span style="color: red">单位:像素(px)</span>。无背景时候默认值:<span style="color: red">20</span>像素。有背景时候默认值:<span style="color: red">20</span>像素。',
|
|
255
255
|
},
|
|
256
|
-
params.poster && params.poster['type']&&
|
|
257
|
-
label: '
|
|
256
|
+
params.poster && params.poster['type'] &¶ms.number > 1 && {
|
|
257
|
+
label: '广告内容之间间距设置:',
|
|
258
258
|
ele: 'el-input',
|
|
259
259
|
type: 'number',
|
|
260
260
|
valueKey: 'padding',
|
|
261
261
|
value: params.padding || 0,
|
|
262
262
|
className: 'input40',
|
|
263
|
-
placeholder: '
|
|
264
|
-
notice: '
|
|
263
|
+
placeholder: '请广告内容之间间距设置',
|
|
264
|
+
notice: '请广告内容之间间距设置。<span style="color: red">单位:像素(px)</span>。默认值:<span style="color: red">0</span>像素',
|
|
265
265
|
inline: false,
|
|
266
266
|
},
|
|
267
267
|
{
|
|
@@ -283,16 +283,28 @@ export default {
|
|
|
283
283
|
},
|
|
284
284
|
},
|
|
285
285
|
{
|
|
286
|
-
|
|
287
|
-
|
|
288
|
-
|
|
289
|
-
|
|
290
|
-
|
|
291
|
-
|
|
292
|
-
|
|
293
|
-
|
|
294
|
-
|
|
295
|
-
|
|
286
|
+
ele: 'title',
|
|
287
|
+
label: '广告位参数配置',
|
|
288
|
+
size: 'small', //default/mini/small
|
|
289
|
+
},
|
|
290
|
+
params.poster && params.poster['type']&& params.poster['type'] !== '1' && {
|
|
291
|
+
label: '广告背景图:',
|
|
292
|
+
ele: 'xd-upload',
|
|
293
|
+
valueKey: 'background',
|
|
294
|
+
value: params.background || {},
|
|
295
|
+
defaultValue: params.background || null,
|
|
296
|
+
slot: true,
|
|
297
|
+
oneWidth: 100,
|
|
298
|
+
oneHeight: 100,
|
|
299
|
+
elinputClassName: 'input40',
|
|
300
|
+
tipsformet: '上传文件格式:@imageType@,不超过@size@MB.',
|
|
301
|
+
type: ['jpg', 'png', 'jpeg'],
|
|
302
|
+
styleType: 'one',
|
|
303
|
+
uploadType: 'aliyun',
|
|
304
|
+
size: 5,
|
|
305
|
+
action: 'action',
|
|
306
|
+
sort: true,
|
|
307
|
+
maxlen: 100,
|
|
296
308
|
},
|
|
297
309
|
{
|
|
298
310
|
label: '广告位置使用张数:',
|
|
@@ -360,7 +372,7 @@ export default {
|
|
|
360
372
|
notice: '在使用非通屏显示类型广告位之外的样式时,<span style="color: red">(显示索引+标题|显示索引)</span>使用"<span style="color: red">显示圆点</span>"',
|
|
361
373
|
inline: false,
|
|
362
374
|
},
|
|
363
|
-
params['isCarousel'] === 2 && {
|
|
375
|
+
params.poster['type'] !== '1' && params['isCarousel'] === 2 && {
|
|
364
376
|
label: '广告位内容显示行数:',
|
|
365
377
|
ele: 'xd-radio',
|
|
366
378
|
valueKey: 'rows',
|
|
@@ -370,7 +382,7 @@ export default {
|
|
|
370
382
|
{"label": "两行", "value": 2},
|
|
371
383
|
]
|
|
372
384
|
},
|
|
373
|
-
params['isCarousel']===2&¶ms['rows']===1&&{
|
|
385
|
+
params['isCarousel']===2 && params['rows'] === 1 && {
|
|
374
386
|
label: '是否启用配套背景:',
|
|
375
387
|
ele: 'xd-radio',
|
|
376
388
|
valueKey: 'isSupport',
|
|
@@ -380,7 +392,6 @@ export default {
|
|
|
380
392
|
{"label": "禁用", "value": 'N'},
|
|
381
393
|
]
|
|
382
394
|
},
|
|
383
|
-
|
|
384
395
|
].filter(i=>i)
|
|
385
396
|
},
|
|
386
397
|
advanced: [
|
|
@@ -31,19 +31,21 @@
|
|
|
31
31
|
class="jfb-base-poster__one notCarousel"
|
|
32
32
|
:style="{
|
|
33
33
|
width: width + 'rpx',
|
|
34
|
-
height:
|
|
35
|
-
borderRadius: (posterType === '1' ? radius: 0) + 'rpx',
|
|
34
|
+
height: outOneHeight + 'rpx',
|
|
36
35
|
}"
|
|
37
36
|
>
|
|
38
|
-
<view
|
|
39
|
-
|
|
40
|
-
|
|
41
|
-
|
|
42
|
-
|
|
43
|
-
|
|
44
|
-
|
|
45
|
-
|
|
46
|
-
|
|
37
|
+
<view
|
|
38
|
+
:style="{
|
|
39
|
+
width: width + 'rpx',
|
|
40
|
+
height: height + 'rpx',
|
|
41
|
+
borderRadius: (posterType === '1' ? radius: 0) + 'rpx',
|
|
42
|
+
marginBottom: padding + 'rpx'
|
|
43
|
+
}"
|
|
44
|
+
@click="handleClick(item)"
|
|
45
|
+
v-for="(item,index) in info"
|
|
46
|
+
:key="index"
|
|
47
|
+
>
|
|
48
|
+
<image :src="item.image_url" mode="aspectFill"></image>
|
|
47
49
|
</view>
|
|
48
50
|
</view>
|
|
49
51
|
<view
|
|
@@ -137,6 +139,7 @@
|
|
|
137
139
|
carouselTime: 5,//轮播图轮播周期
|
|
138
140
|
useNumber: null, //广告使用张数
|
|
139
141
|
height: 0, //广告高度
|
|
142
|
+
outOneHeight:0,//焦点图显示高度
|
|
140
143
|
width: 0, //广告高度
|
|
141
144
|
padding: 0, //广告内容之间间距
|
|
142
145
|
rows: 1, //四分屏起作用
|
|
@@ -177,9 +180,13 @@
|
|
|
177
180
|
},
|
|
178
181
|
computed: {
|
|
179
182
|
getConfig(){
|
|
180
|
-
let cell = this.posterType === '2' ? 2: (this.posterType === '3' ? 3: 4);
|
|
183
|
+
let cell = this.posterType === '2' ? 2: (this.posterType === '3' ? 3 : 4);
|
|
181
184
|
let spacing = Math.floor((cell - 1) * this.padding * this.$rpxNum);
|
|
182
|
-
let
|
|
185
|
+
let padding = 0;
|
|
186
|
+
if(this.$xdUniHelper.isEmpty(this.background)) padding = 20;
|
|
187
|
+
let addPadding = ((this.bgImagePadding.right !== null? this.bgImagePadding.right:padding) +
|
|
188
|
+
(this.bgImagePadding.left !== null? this.bgImagePadding.left : padding)) * this.$rpxNum;
|
|
189
|
+
let viewWidth = uni.getSystemInfoSync().safeArea.width - ((this.mS.right || 0) + (this.mS.left || 0)) * this.$rpxNum - addPadding - spacing;
|
|
183
190
|
if(this.$configProject.isPreview) viewWidth -= 2;
|
|
184
191
|
let width = Math.floor(viewWidth / cell);
|
|
185
192
|
let height = this.height * width / this.width;
|
|
@@ -288,7 +295,7 @@
|
|
|
288
295
|
} catch (error) {
|
|
289
296
|
console.log(error,'amamamam');
|
|
290
297
|
}
|
|
291
|
-
|
|
298
|
+
|
|
292
299
|
},
|
|
293
300
|
},
|
|
294
301
|
watch: {
|
|
@@ -381,7 +388,6 @@
|
|
|
381
388
|
this.current = e.detail.current;
|
|
382
389
|
}
|
|
383
390
|
},
|
|
384
|
-
|
|
385
391
|
handleClick(item) {
|
|
386
392
|
//内部链接跳转地址
|
|
387
393
|
if (item.redirect_type === 'INN') {
|
|
@@ -486,6 +492,7 @@
|
|
|
486
492
|
if(this.poster.size) {
|
|
487
493
|
this.width = this.poster.size.width;
|
|
488
494
|
this.height = this.poster.size.height;
|
|
495
|
+
this.outOneHeight = this.height * Number(this.useNumber) + (Number(this.padding) * (Number(this.useNumber) - 1));
|
|
489
496
|
}
|
|
490
497
|
},
|
|
491
498
|
|
|
@@ -567,16 +574,19 @@
|
|
|
567
574
|
display: flex;
|
|
568
575
|
justify-content: center;
|
|
569
576
|
align-items: center;
|
|
570
|
-
|
|
571
|
-
|
|
577
|
+
flex-flow: wrap;
|
|
572
578
|
|
|
573
579
|
& > view {
|
|
574
|
-
width: 100%;
|
|
575
|
-
height: 100%;
|
|
576
580
|
box-sizing: border-box;
|
|
581
|
+
overflow: hidden;
|
|
577
582
|
|
|
578
|
-
|
|
583
|
+
&:last-child {
|
|
584
|
+
margin-bottom: 0!important;
|
|
585
|
+
}
|
|
579
586
|
|
|
587
|
+
& > image {
|
|
588
|
+
width: 100%;
|
|
589
|
+
height: 100%;
|
|
580
590
|
}
|
|
581
591
|
}
|
|
582
592
|
}
|
|
@@ -48,6 +48,7 @@
|
|
|
48
48
|
<template slot-scope="{ item, index}">
|
|
49
49
|
<view
|
|
50
50
|
class="sreen__box-list"
|
|
51
|
+
:class="{s3:config.cell === 3,s4:config.cell === 4}"
|
|
51
52
|
:style="{
|
|
52
53
|
height: getHeight + 'px'
|
|
53
54
|
}"
|
|
@@ -256,6 +257,14 @@
|
|
|
256
257
|
flex-wrap: wrap;
|
|
257
258
|
overflow: hidden;
|
|
258
259
|
|
|
260
|
+
&.s3 > view:nth-child(3n) {
|
|
261
|
+
margin-right: 0 !important;
|
|
262
|
+
}
|
|
263
|
+
|
|
264
|
+
&.s4 > view:nth-child(4n) {
|
|
265
|
+
margin-right: 0 !important;
|
|
266
|
+
}
|
|
267
|
+
|
|
259
268
|
& view {
|
|
260
269
|
display: flex;
|
|
261
270
|
justify-content: center;
|
|
@@ -264,10 +273,6 @@
|
|
|
264
273
|
box-sizing: border-box;
|
|
265
274
|
overflow: hidden;
|
|
266
275
|
|
|
267
|
-
&:nth-child(4n) {
|
|
268
|
-
margin-right: 0 !important;
|
|
269
|
-
}
|
|
270
|
-
|
|
271
276
|
& > image {
|
|
272
277
|
|
|
273
278
|
}
|
|
@@ -321,7 +321,7 @@ import XdFontIcon from "@/components/XdFontIcon/XdFontIcon";
|
|
|
321
321
|
import XdDailog from "@/components/XdDailog/XdDailog";
|
|
322
322
|
import XdButton from "@/components/XdButton/XdButton";
|
|
323
323
|
import XdUnit from "@/components/XdUnit/XdUnit";
|
|
324
|
-
import { jfbRootExec
|
|
324
|
+
import { jfbRootExec } from "@/utils/xd.event";
|
|
325
325
|
import JfbBaseSuccessMixin from "./JfbBaseSuccessMixin";
|
|
326
326
|
import componentsMixins from "@/mixins/componentsMixins";
|
|
327
327
|
import extsMixins from "@/mixins/extsMixins";
|
|
@@ -495,9 +495,6 @@ export default {
|
|
|
495
495
|
},
|
|
496
496
|
})
|
|
497
497
|
.then((res) => {
|
|
498
|
-
if(res.status.status_type === 'success') {
|
|
499
|
-
jfbRootFnExec(this, 'onCustomEvent')("@showBaseConDialog", {order_id: this.order_id});
|
|
500
|
-
}
|
|
501
498
|
this.handleOrderResolve(res);
|
|
502
499
|
})
|
|
503
500
|
.catch((err) => {
|
|
@@ -1,197 +0,0 @@
|
|
|
1
|
-
<template>
|
|
2
|
-
<view class="xd-cou-card-bind">
|
|
3
|
-
<view class="ticket_box" :style="{
|
|
4
|
-
backgroundImage: dialogBackground
|
|
5
|
-
}">
|
|
6
|
-
<view class="ticket_list">
|
|
7
|
-
<view class="ticket_item" :class="item.can_take_num"
|
|
8
|
-
v-for="(item,i) in uiList" :key="i"
|
|
9
|
-
:style="{backgroundImage: item.backgroundImage}"
|
|
10
|
-
>
|
|
11
|
-
<view class="ticket_names">
|
|
12
|
-
<view class="name_main">{{item.prize_type}}</view>
|
|
13
|
-
<view class="name_sub">{{item.prize_name}}</view>
|
|
14
|
-
</view>
|
|
15
|
-
<view class="name_tit">{{item.prize_name}}</view>
|
|
16
|
-
<xd-font-icon class="ticket_icon" :icon="item.icon"></xd-font-icon>
|
|
17
|
-
<view class="btn">
|
|
18
|
-
<xd-button
|
|
19
|
-
size="small"
|
|
20
|
-
type="primary"
|
|
21
|
-
:disabled="item.remain_card_count == 0"
|
|
22
|
-
:style="{
|
|
23
|
-
backgroundImage: item.btnImage
|
|
24
|
-
}"
|
|
25
|
-
@click="getCoupont(item)"
|
|
26
|
-
>{{item.btn_txt}}</xd-button>
|
|
27
|
-
</view>
|
|
28
|
-
</view>
|
|
29
|
-
</view>
|
|
30
|
-
</view>
|
|
31
|
-
|
|
32
|
-
<xd-font-icon
|
|
33
|
-
@click="handleClose"
|
|
34
|
-
class="dialog_close"
|
|
35
|
-
icon="iconguanbi_xian"
|
|
36
|
-
color="#fff"
|
|
37
|
-
size="64"
|
|
38
|
-
></xd-font-icon>
|
|
39
|
-
</view>
|
|
40
|
-
</template>
|
|
41
|
-
<script>
|
|
42
|
-
import XdButton from "@/components/XdButton/XdButton";
|
|
43
|
-
import XdFontIcon from "@/components/XdFontIcon/XdFontIcon";
|
|
44
|
-
import getServiceUrl from "@/common/getServiceUrl";
|
|
45
|
-
export default{
|
|
46
|
-
name: "XdCouCardBind",
|
|
47
|
-
components: {
|
|
48
|
-
XdButton,
|
|
49
|
-
XdFontIcon
|
|
50
|
-
},
|
|
51
|
-
props: {
|
|
52
|
-
list: {
|
|
53
|
-
type: Array,
|
|
54
|
-
default(){
|
|
55
|
-
return []
|
|
56
|
-
}
|
|
57
|
-
},
|
|
58
|
-
setting: {}
|
|
59
|
-
},
|
|
60
|
-
computed: {
|
|
61
|
-
uiList(){
|
|
62
|
-
return this.list.map(item => {
|
|
63
|
-
let mapArr = {"Y": "去查看", "P": "领取", "N": "已发完"}
|
|
64
|
-
item.btn_txt = mapArr[item.can_take_num];
|
|
65
|
-
if(item.can_take_num === "Y" || item.can_take_num === "P"){
|
|
66
|
-
item.backgroundImage = `url(${getServiceUrl(this.setting.app_coupon_url)})`;
|
|
67
|
-
item.btnImage = `url(${getServiceUrl(this.setting.app_coupon_button_bg_url)})`;
|
|
68
|
-
item.icon = item.can_take_num === "Y" ? "iconyilingqu" : "icondailingqu";
|
|
69
|
-
}else if(item.can_take_num === "N"){
|
|
70
|
-
item.backgroundImage = `url(${getServiceUrl(this.setting.app_coupon_invalid_url)})`;
|
|
71
|
-
item.btnImage = "";
|
|
72
|
-
item.icon = "iconyifawan";
|
|
73
|
-
}
|
|
74
|
-
return item;
|
|
75
|
-
})
|
|
76
|
-
},
|
|
77
|
-
dialogBackground(){
|
|
78
|
-
return `url(${getServiceUrl(this.setting.background)})`;
|
|
79
|
-
}
|
|
80
|
-
},
|
|
81
|
-
data(){
|
|
82
|
-
return {
|
|
83
|
-
|
|
84
|
-
}
|
|
85
|
-
},
|
|
86
|
-
methods: {
|
|
87
|
-
//领取优惠券
|
|
88
|
-
getCoupont(item){
|
|
89
|
-
if(item.can_take_num === "P"){
|
|
90
|
-
this.$emit("getCoupont", item);
|
|
91
|
-
}
|
|
92
|
-
},
|
|
93
|
-
handleClose(){
|
|
94
|
-
this.$emit("closeDialog");
|
|
95
|
-
}
|
|
96
|
-
}
|
|
97
|
-
}
|
|
98
|
-
</script>
|
|
99
|
-
|
|
100
|
-
<style lang="less" scoped>
|
|
101
|
-
@ticketHeight: 180rpx;
|
|
102
|
-
@bgHeight: @ticketHeight - 40rpx;
|
|
103
|
-
.xd-cou-card-bind{
|
|
104
|
-
width: 600rpx;
|
|
105
|
-
max-height: 800rpx;
|
|
106
|
-
padding-bottom: 80rpx;
|
|
107
|
-
.ticket_box{
|
|
108
|
-
background-color: #fff;
|
|
109
|
-
background-size: 100% auto;
|
|
110
|
-
background-repeat: no-repeat;
|
|
111
|
-
padding-top: 100rpx;
|
|
112
|
-
border-radius: 20rpx;
|
|
113
|
-
box-sizing: border-box;
|
|
114
|
-
padding-bottom: 20rpx;
|
|
115
|
-
}
|
|
116
|
-
|
|
117
|
-
.ticket_item{
|
|
118
|
-
display: flex;
|
|
119
|
-
position: relative;
|
|
120
|
-
width: 540rpx;
|
|
121
|
-
height: @ticketHeight;
|
|
122
|
-
margin: 20rpx auto;
|
|
123
|
-
border-radius: 20rpx;
|
|
124
|
-
padding: 30rpx;
|
|
125
|
-
box-sizing: border-box;
|
|
126
|
-
background: #EEEEEE url("//sandbox-img.jufubao.cn/uploads/20231205/fee9b644b83495c9ba8a4db277600b54.jpg") no-repeat;
|
|
127
|
-
background-size: auto @bgHeight;
|
|
128
|
-
background-position: 30rpx center;
|
|
129
|
-
|
|
130
|
-
&.P,
|
|
131
|
-
&.Y{
|
|
132
|
-
|
|
133
|
-
}
|
|
134
|
-
&.N{
|
|
135
|
-
.ticket_names{
|
|
136
|
-
.name_main{
|
|
137
|
-
color: #BBBBBB;
|
|
138
|
-
}
|
|
139
|
-
}
|
|
140
|
-
.ticket_icon{
|
|
141
|
-
color: #D6D6D6;
|
|
142
|
-
|
|
143
|
-
}
|
|
144
|
-
.btn{
|
|
145
|
-
.xd-button{
|
|
146
|
-
background-color: #DDDDDD !important;
|
|
147
|
-
color: #999999 !important;
|
|
148
|
-
}
|
|
149
|
-
}
|
|
150
|
-
}
|
|
151
|
-
.name_tit{
|
|
152
|
-
font-size: 28rpx;
|
|
153
|
-
margin-left: 20rpx;
|
|
154
|
-
}
|
|
155
|
-
.ticket_names{
|
|
156
|
-
width: 168rpx;
|
|
157
|
-
height: 120rpx;
|
|
158
|
-
text-align: center;
|
|
159
|
-
font-size: 28rpx;
|
|
160
|
-
.name_main{
|
|
161
|
-
margin-bottom: 26rpx;
|
|
162
|
-
margin-top: 20rpx;
|
|
163
|
-
color: #fb5b3f;
|
|
164
|
-
}
|
|
165
|
-
.name_sub{
|
|
166
|
-
font-size: 24rpx;
|
|
167
|
-
color: #FFFFFF;
|
|
168
|
-
}
|
|
169
|
-
}
|
|
170
|
-
.ticket_icon{
|
|
171
|
-
font-size: 80rpx !important;
|
|
172
|
-
position: absolute;
|
|
173
|
-
top: 0;
|
|
174
|
-
right: 0;
|
|
175
|
-
}
|
|
176
|
-
.btn{
|
|
177
|
-
position: absolute;
|
|
178
|
-
right: 20rpx;
|
|
179
|
-
bottom: 20rpx;
|
|
180
|
-
.xd-button{
|
|
181
|
-
height: 30rpx;
|
|
182
|
-
width: 100rpx;
|
|
183
|
-
font-size: 28rpx;
|
|
184
|
-
background-size: cover !important;
|
|
185
|
-
background-color: #fb5b3f;
|
|
186
|
-
}
|
|
187
|
-
}
|
|
188
|
-
|
|
189
|
-
}
|
|
190
|
-
.dialog_close{
|
|
191
|
-
position: absolute;
|
|
192
|
-
bottom: 0rpx;
|
|
193
|
-
left: 50%;
|
|
194
|
-
transform: translateX(-50%);
|
|
195
|
-
}
|
|
196
|
-
}
|
|
197
|
-
</style>
|