jufubao-mall 2.0.32 → 2.0.34
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/CusCouponChose/CusCouponChose.vue +10 -13
- package/src/components/CusEnter/CusEnter.vue +9 -1
- package/src/components/CusListItem/CusListItem.vue +141 -0
- package/src/components/CusPoster/CusPoster.vue +17 -62
- package/src/components/CusPrice/CusPrice.vue +391 -0
- package/src/components/CusProduct/CusProduct.vue +576 -184
- package/src/components/CusShops/CusShops.vue +409 -209
- package/src/components/CusTab/CusTab.vue +159 -22
- package/src/components/CusVipList/CusVipList.vue +169 -0
- package/src/components/JfbMallConfirm/Api.js +1 -1
- package/src/components/JfbMallConfirm/Attr.js +167 -453
- package/src/components/JfbMallConfirm/JfbMallConfirm.vue +362 -162
- package/src/components/JfbMallConfirm/Mock.js +61 -43
- package/src/components/JfbMallConfirm/XdAddrDefault.vue +26 -13
- package/src/components/JfbMallConfirm/XdAddrOld.vue +9 -7
- package/src/components/JfbMallConfirm/XdListItem.vue +10 -2
- package/src/components/JfbMallConfirm/cusAttr/advanced.js +91 -0
- package/src/components/JfbMallConfirm/cusAttr/content.js +355 -0
- package/src/components/JfbMallConfirm/cusAttr/style.js +628 -0
- package/src/components/JfbMallConfirm/shopList.vue +84 -42
- package/src/components/JfbMallNetworkMedia/Api.js +94 -0
- package/src/components/JfbMallNetworkMedia/Attr.js +20 -0
- package/src/components/JfbMallNetworkMedia/JfbMallNetworkMedia.vue +1167 -0
- package/src/components/JfbMallNetworkMedia/JfbMallNetworkMediaLess.less +80 -0
- package/src/components/JfbMallNetworkMedia/JfbMallNetworkMediaMixin.js +30 -0
- package/src/components/JfbMallNetworkMedia/Mock.js +372 -0
- package/src/components/JfbMallNetworkMedia/cusAttr/advanced.js +60 -0
- package/src/components/JfbMallNetworkMedia/cusAttr/content.js +230 -0
- package/src/components/JfbMallNetworkMedia/cusAttr/font.js +123 -0
- package/src/components/JfbMallNetworkMedia/cusAttr/icon.js +257 -0
- package/src/components/JfbMallNetworkMedia/cusAttr/style.js +12 -0
- package/src/components/JfbMallProductInfo/cusAttr/content.js +2 -0
- package/src/components/JfbMallProductList/JfbMallProductList.vue +7 -1
- package/src/components/JfbMallProductList/XdCateV1.vue +0 -1
- package/src/components/JfbMallShop/JfbMallShop.vue +1 -1
- package/src/components/JfbMallShop/cusAttr/content.js +1 -1
- package/src/components/SkeProduct/SkeProduct.vue +88 -3
|
@@ -1,36 +1,49 @@
|
|
|
1
1
|
<template>
|
|
2
2
|
<view
|
|
3
3
|
class="xd-tab"
|
|
4
|
+
v-if="eleID"
|
|
4
5
|
:class="{noBorder: noBorder}"
|
|
5
6
|
:style="{background:bgColor}"
|
|
6
7
|
>
|
|
8
|
+
|
|
7
9
|
<scroll-view
|
|
8
10
|
class="tab-scroll"
|
|
9
11
|
scroll-x
|
|
10
12
|
:scroll-with-animation="scrollWithAnimation"
|
|
11
13
|
:scroll-into-view="toView"
|
|
14
|
+
:id="eleID"
|
|
12
15
|
:style="{
|
|
13
16
|
width: 'calc(100% - '+ getSettingWidth + 'px)',
|
|
14
17
|
height: height + 'rpx'
|
|
15
18
|
}"
|
|
16
|
-
|
|
19
|
+
@scroll="handleScroll"
|
|
17
20
|
>
|
|
18
21
|
<view class="tab-scroll__box">
|
|
19
22
|
<view
|
|
20
23
|
:id="`tab-scroll__index-${index}`"
|
|
21
24
|
v-for="(item, index) in list"
|
|
22
25
|
:key="index"
|
|
23
|
-
:style="{
|
|
26
|
+
:style="{
|
|
27
|
+
color: activeIndex === index? (actColor||styleMainColor): color,
|
|
28
|
+
height: height + 'rpx',
|
|
29
|
+
width: (getItemWidth(item) + (index===0?spacing:0)) + 'rpx',
|
|
30
|
+
margin: (actBgcColor || bgcColor)? 0:`0 0 0 ${spacing}rpx`
|
|
31
|
+
}"
|
|
24
32
|
class="tab-scroll__item"
|
|
25
|
-
:class="{active:activeIndex === index}"
|
|
33
|
+
:class="{active:activeIndex === index,'desc': xAbsolute === 'none' && item.subName}"
|
|
26
34
|
@click="clickTab(item, index)"
|
|
27
35
|
>
|
|
28
36
|
<view
|
|
29
37
|
:style="[{
|
|
38
|
+
width: getItemWidth(item) + 'rpx',
|
|
30
39
|
fontWeight: activeIndex === index? actFontWeight: fontWeight,
|
|
31
40
|
fontSize: (activeIndex === index ? actFontSize : fontSize) + 'rpx',
|
|
32
41
|
height:(xAbsolute === 'none' && item.subName)?(height/2 + 'rpx'):(height + 'rpx'),
|
|
33
|
-
lineHeight:(xAbsolute === 'none' && item.subName)?(height/2 + 'rpx'):(height + 'rpx')
|
|
42
|
+
lineHeight:(xAbsolute === 'none' && item.subName)?(height/2 + 'rpx'):(height + 'rpx'),
|
|
43
|
+
backgroundColor: activeIndex === index?actBgcColor:bgcColor,
|
|
44
|
+
borderRadius: (actBgcColor||bgcColor)? '30rpx':0,
|
|
45
|
+
padding: (actBgcColor||bgcColor) ? '0 16rpx':0,
|
|
46
|
+
marginLeft: index === 0? `${spacing}rpx`: 0
|
|
34
47
|
}]">{{item.name}}</view>
|
|
35
48
|
<view
|
|
36
49
|
class="xAbsolute"
|
|
@@ -38,6 +51,7 @@
|
|
|
38
51
|
:style="[
|
|
39
52
|
footerStyleComp,
|
|
40
53
|
{backgroundColor: activeIndex === index? (actColor||styleMainColor): ''},
|
|
54
|
+
{left: `calc(50% + ${index === 0 ? `${spacing/2}rpx`: '0rpx'})`}
|
|
41
55
|
]"
|
|
42
56
|
>
|
|
43
57
|
<view
|
|
@@ -49,11 +63,33 @@
|
|
|
49
63
|
<view
|
|
50
64
|
v-if="xAbsolute === 'none' && item.subName"
|
|
51
65
|
class="none"
|
|
52
|
-
:style="[
|
|
66
|
+
:style="[
|
|
67
|
+
activeIndex === index?subActNameComp:subNameComp,
|
|
68
|
+
{marginLeft: index === 0? `${spacing}rpx`: 0},
|
|
69
|
+
{maxWidth: getItemWidth(item) + 'rpx'}
|
|
70
|
+
]"
|
|
53
71
|
>{{item.subName}}</view>
|
|
72
|
+
<view
|
|
73
|
+
class="xAbsolute triangle"
|
|
74
|
+
v-if="xAbsolute === 'triangle' && activeIndex === index"
|
|
75
|
+
:style="[{left: `calc(50% + ${index === 0 ? '24rpx': '0rpx'})`}]"
|
|
76
|
+
>
|
|
77
|
+
<xd-font-icon icon="iconrepository-xialaxuanxiangup" size="22" :color="actColor||styleMainColor"></xd-font-icon>
|
|
78
|
+
</view>
|
|
79
|
+
<view
|
|
80
|
+
class="xAbsolute center"
|
|
81
|
+
v-if="xAbsolute === 'center' && activeIndex === index"
|
|
82
|
+
:style="[
|
|
83
|
+
{background: activeIndex === index? (actColor||styleMainColor): color},
|
|
84
|
+
{left: `calc(50% + ${index === 0 ? `${spacing/2}rpx`: '0rpx'})`}
|
|
85
|
+
]"
|
|
86
|
+
></view>
|
|
54
87
|
</view>
|
|
55
88
|
</view>
|
|
56
89
|
</scroll-view>
|
|
90
|
+
<view class="center" v-if="xAbsolute === 'center'">
|
|
91
|
+
<view :style="{left:left, background: styleMainColor}"></view>
|
|
92
|
+
</view>
|
|
57
93
|
<view
|
|
58
94
|
class="tab-icons"
|
|
59
95
|
@click="handleClickSetting"
|
|
@@ -90,6 +126,10 @@
|
|
|
90
126
|
return {}
|
|
91
127
|
},
|
|
92
128
|
},
|
|
129
|
+
spacing:{
|
|
130
|
+
type: Number,
|
|
131
|
+
default: 40
|
|
132
|
+
},
|
|
93
133
|
settingWidth: {
|
|
94
134
|
type: Number,
|
|
95
135
|
default: 70
|
|
@@ -148,6 +188,14 @@
|
|
|
148
188
|
type: Number | String, //rpx
|
|
149
189
|
default: 500
|
|
150
190
|
},
|
|
191
|
+
bgcColor: {
|
|
192
|
+
type: String,
|
|
193
|
+
default: ''
|
|
194
|
+
},
|
|
195
|
+
actBgcColor: {
|
|
196
|
+
type: String,
|
|
197
|
+
default: ''
|
|
198
|
+
},
|
|
151
199
|
height: {
|
|
152
200
|
type: Number | String, //rpx
|
|
153
201
|
default: 90
|
|
@@ -159,10 +207,11 @@
|
|
|
159
207
|
actColor: {
|
|
160
208
|
type: String,
|
|
161
209
|
default: ''
|
|
162
|
-
}
|
|
210
|
+
},
|
|
163
211
|
},
|
|
164
212
|
data() {
|
|
165
213
|
return {
|
|
214
|
+
eleID:null,
|
|
166
215
|
activeIndex: 0,
|
|
167
216
|
toView: null,
|
|
168
217
|
styleMainColor: '', //插件主题风格样式
|
|
@@ -174,6 +223,11 @@
|
|
|
174
223
|
|
|
175
224
|
xAbsolute: 'absolute',//绝对定位|无
|
|
176
225
|
styleSolid: 'Y',
|
|
226
|
+
itemWidth: 0,
|
|
227
|
+
|
|
228
|
+
//居中处理
|
|
229
|
+
left:0,
|
|
230
|
+
boxWidth:0
|
|
177
231
|
};
|
|
178
232
|
},
|
|
179
233
|
|
|
@@ -185,19 +239,17 @@
|
|
|
185
239
|
return 0;
|
|
186
240
|
},
|
|
187
241
|
footerStyleComp(){
|
|
188
|
-
//circle/line/none/trigon/desc
|
|
189
242
|
let temp = {};
|
|
190
243
|
temp['bottom'] = this.lineBottom + 'rpx';
|
|
191
244
|
if(this.styleType === 'line') {
|
|
192
245
|
temp['height'] = this.styleHeight + 'rpx';
|
|
193
|
-
temp['
|
|
194
|
-
temp['
|
|
246
|
+
temp['width'] = '64rpx';
|
|
247
|
+
temp['transform'] = 'translateX(-50%)';
|
|
195
248
|
temp['borderRadius'] = this.styleRadius;
|
|
196
249
|
}
|
|
197
250
|
if(this.styleType === 'circle'){
|
|
198
251
|
temp['height'] = this.styleHeight + 'rpx';
|
|
199
252
|
temp['width'] = this.styleHeight + 'rpx';
|
|
200
|
-
temp['left'] = '50%';
|
|
201
253
|
temp['marginLeft'] = -this.styleHeight/2 + 'rpx'
|
|
202
254
|
temp['borderRadius'] = this.styleRadius;
|
|
203
255
|
}
|
|
@@ -211,7 +263,6 @@
|
|
|
211
263
|
temp['backgroundColor'] = '#fff';
|
|
212
264
|
if(this.styleType === 'circle'){
|
|
213
265
|
temp['borderRadius'] = '50%';
|
|
214
|
-
|
|
215
266
|
}
|
|
216
267
|
return temp
|
|
217
268
|
},
|
|
@@ -251,6 +302,7 @@
|
|
|
251
302
|
},
|
|
252
303
|
},
|
|
253
304
|
async created() {
|
|
305
|
+
this.eleID = `tab-${this.$xdUniHelper.randomChar(5)}`;
|
|
254
306
|
this.initStyle();
|
|
255
307
|
this.styleMainColor = await getParentsStyle(this.$parent, '$mainColor');
|
|
256
308
|
},
|
|
@@ -270,6 +322,14 @@
|
|
|
270
322
|
this.toView = `tab-scroll__index-${this.tabIndex}`;
|
|
271
323
|
this.$emit('onInit', this.list[this.activeIndex], this.activeIndex);
|
|
272
324
|
}
|
|
325
|
+
|
|
326
|
+
const query = uni.createSelectorQuery().in(this);
|
|
327
|
+
query
|
|
328
|
+
.select(`#${this.eleID }`)
|
|
329
|
+
.boundingClientRect((data) => {
|
|
330
|
+
this.boxWidth = data.width;
|
|
331
|
+
})
|
|
332
|
+
.exec();
|
|
273
333
|
});
|
|
274
334
|
},
|
|
275
335
|
|
|
@@ -278,10 +338,19 @@
|
|
|
278
338
|
let arr = this.footerStyle.split('-');
|
|
279
339
|
this.styleType = arr[0];
|
|
280
340
|
this.xAbsolute = 'absolute';
|
|
341
|
+
|
|
281
342
|
if(this.styleType === 'desc') {
|
|
282
343
|
this.xAbsolute = 'none';
|
|
283
344
|
}
|
|
284
345
|
|
|
346
|
+
if(this.styleType === 'center') {
|
|
347
|
+
this.xAbsolute = 'center';
|
|
348
|
+
}
|
|
349
|
+
|
|
350
|
+
if(this.styleType === 'triangle') {
|
|
351
|
+
this.xAbsolute = 'triangle';
|
|
352
|
+
}
|
|
353
|
+
|
|
285
354
|
//圆与三角
|
|
286
355
|
if(arr.length === 3) {
|
|
287
356
|
this.styleHeight = this.styleWidth = Number(arr[1])
|
|
@@ -293,14 +362,25 @@
|
|
|
293
362
|
|
|
294
363
|
//线
|
|
295
364
|
if(arr.length === 4) {
|
|
296
|
-
this.styleHeight =
|
|
297
|
-
this.styleRadius =
|
|
365
|
+
this.styleHeight = 6;
|
|
366
|
+
this.styleRadius = 4 + 'rpx';
|
|
298
367
|
if(arr[3] === 'l') this.styleLong = '20rpx'
|
|
299
368
|
else this.styleLong = '35%'
|
|
300
369
|
}
|
|
301
370
|
|
|
302
371
|
},
|
|
303
372
|
|
|
373
|
+
getItemWidth(item){
|
|
374
|
+
let maxFontSize = Math.max(parseInt(this.actFontSize),parseInt(this.fontSize))
|
|
375
|
+
let nameWidth = item.name.length * maxFontSize;
|
|
376
|
+
let actFontSize = Math.max(parseInt(this.subNameStyle['actFontSize']||24),parseInt(this.subNameStyle['fontSize']||24))
|
|
377
|
+
let subNameWidth = this.xAbsolute==='none' ? (item.subName.length * actFontSize): 0;
|
|
378
|
+
if(this.actBgcColor || this.bgcColor) {
|
|
379
|
+
nameWidth += 16*2
|
|
380
|
+
}
|
|
381
|
+
return Math.max(nameWidth,subNameWidth);
|
|
382
|
+
},
|
|
383
|
+
|
|
304
384
|
clickTab(item, index) {
|
|
305
385
|
this.activeIndex = index;
|
|
306
386
|
this.toView = `tab-scroll__index-${this.activeIndex}`;
|
|
@@ -309,6 +389,14 @@
|
|
|
309
389
|
handleClickSetting(){
|
|
310
390
|
this.$emit('onSetting');
|
|
311
391
|
},
|
|
392
|
+
|
|
393
|
+
handleScroll({detail}){
|
|
394
|
+
if(this.xAbsolute === 'center'){
|
|
395
|
+
let maxScrollW = detail.scrollWidth - this.boxWidth;
|
|
396
|
+
this.left = ((detail.scrollLeft* 30 * this.$rpxNum)/ maxScrollW) + 'px';
|
|
397
|
+
}
|
|
398
|
+
|
|
399
|
+
}
|
|
312
400
|
}
|
|
313
401
|
}
|
|
314
402
|
</script>
|
|
@@ -322,10 +410,30 @@
|
|
|
322
410
|
flex-wrap: wrap;
|
|
323
411
|
overflow: hidden;
|
|
324
412
|
padding: 0;
|
|
325
|
-
|
|
413
|
+
position: relative;
|
|
326
414
|
&.noBorder {
|
|
327
415
|
border-bottom: 1px #f5f5f5 solid;
|
|
328
416
|
}
|
|
417
|
+
& > .center {
|
|
418
|
+
position: absolute;
|
|
419
|
+
height: 8rpx;
|
|
420
|
+
left: 50%;
|
|
421
|
+
bottom: 8rpx;
|
|
422
|
+
width: 80rpx;
|
|
423
|
+
margin-left: -40rpx;
|
|
424
|
+
border-radius: 5rpx;
|
|
425
|
+
background-color: #ccc;
|
|
426
|
+
overflow: hidden;
|
|
427
|
+
&> view {
|
|
428
|
+
position: absolute;
|
|
429
|
+
top:0;
|
|
430
|
+
bottom: 0;
|
|
431
|
+
width: 50rpx;
|
|
432
|
+
border-radius: 5rpx;
|
|
433
|
+
height: 8rpx;
|
|
434
|
+
background-color: #ccc;
|
|
435
|
+
}
|
|
436
|
+
}
|
|
329
437
|
|
|
330
438
|
.tab-scroll {
|
|
331
439
|
.tab-scroll__box {
|
|
@@ -335,19 +443,29 @@
|
|
|
335
443
|
box-sizing: border-box;
|
|
336
444
|
|
|
337
445
|
.tab-scroll__item {
|
|
446
|
+
position: relative;
|
|
338
447
|
flex-shrink: 0;
|
|
339
|
-
padding: 0
|
|
448
|
+
padding: 0;
|
|
340
449
|
color: #333;
|
|
341
450
|
font-size: unit(30, rpx);
|
|
342
451
|
height: unit(100, rpx);
|
|
343
|
-
position: relative;
|
|
344
452
|
display: flex;
|
|
345
453
|
align-items: center;
|
|
346
454
|
align-content: center;
|
|
347
455
|
flex-flow: column;
|
|
456
|
+
text-align: center;
|
|
457
|
+
&:first-child {
|
|
458
|
+
margin-left: 0!important;
|
|
459
|
+
}
|
|
460
|
+
|
|
461
|
+
&.desc {
|
|
462
|
+
justify-content: center;
|
|
463
|
+
min-width: 3.5rem;
|
|
464
|
+
}
|
|
465
|
+
|
|
348
466
|
|
|
349
467
|
|
|
350
|
-
|
|
468
|
+
&.active {
|
|
351
469
|
color: @xd-base-color;
|
|
352
470
|
}
|
|
353
471
|
|
|
@@ -358,15 +476,34 @@
|
|
|
358
476
|
display: flex;
|
|
359
477
|
justify-content: center;
|
|
360
478
|
align-items: center;
|
|
479
|
+
line-height: 1.1rem;
|
|
480
|
+
|
|
481
|
+
&.triangle {
|
|
482
|
+
bottom: unit(0,rpx);
|
|
483
|
+
transform: translateX(-50%);
|
|
484
|
+
}
|
|
485
|
+
|
|
486
|
+
&.center {
|
|
487
|
+
position: absolute;
|
|
488
|
+
bottom: 22rpx;
|
|
489
|
+
width: 70rpx;
|
|
490
|
+
height: 10rpx;
|
|
491
|
+
opacity: .25;
|
|
492
|
+
border-radius:40%;
|
|
493
|
+
z-index: 0;
|
|
494
|
+
transform: translateX(-50%);
|
|
495
|
+
}
|
|
361
496
|
}
|
|
362
497
|
|
|
363
498
|
& > view.none {
|
|
364
|
-
padding:
|
|
499
|
+
padding:0;
|
|
500
|
+
text-align: center;
|
|
365
501
|
color:#000;
|
|
366
|
-
border-radius:
|
|
367
|
-
|
|
368
|
-
|
|
369
|
-
|
|
502
|
+
border-radius:18rpx;
|
|
503
|
+
width: 100%;
|
|
504
|
+
font-size: 24rpx;
|
|
505
|
+
line-height: 36rpx;
|
|
506
|
+
height: 36rpx;
|
|
370
507
|
}
|
|
371
508
|
}
|
|
372
509
|
}
|
|
@@ -0,0 +1,169 @@
|
|
|
1
|
+
<template>
|
|
2
|
+
<view class="vip-list_wrap">
|
|
3
|
+
<view class="vip_cards-header">
|
|
4
|
+
<xd-font-icon icon="iconPLUShuiyuan" :size="24" color="#FCBF28"></xd-font-icon>
|
|
5
|
+
<view class="vip_title">开通会员,本单可省
|
|
6
|
+
<text class="vip_title-price"> {{$xdUniHelper.divisionFloatNumber(plus_saving_money, 100)}}</text>
|
|
7
|
+
<!-- <xd-unit :price="plus_saving_money" :isOld="false" :fontSize="24" :iconSize="0.3" style="margin-left: 8rpx;"></xd-unit> -->
|
|
8
|
+
</view>
|
|
9
|
+
</view>
|
|
10
|
+
<view class="vip_cards-body">
|
|
11
|
+
<view class="vip_card_list">
|
|
12
|
+
<view class="vip_item" :class="{active: vipCardId==item.vip_card_id}"
|
|
13
|
+
v-for="item in list" :key="item.vip_card_id"
|
|
14
|
+
@click="handleChoseVipCard(item)"
|
|
15
|
+
>
|
|
16
|
+
<view class="vip_name">{{ item.product_name }}</view>
|
|
17
|
+
<view class="vip_img">
|
|
18
|
+
<image :src="item.vip_card_icon"></image>
|
|
19
|
+
</view>
|
|
20
|
+
<view class="vip_price">{{ $xdUniHelper.divisionFloatNumber(item.sale_price, 100) }}</view>
|
|
21
|
+
</view>
|
|
22
|
+
</view>
|
|
23
|
+
</view>
|
|
24
|
+
</view>
|
|
25
|
+
</template>
|
|
26
|
+
|
|
27
|
+
<script>
|
|
28
|
+
import XdFontIcon from "@/components/XdFontIcon/XdFontIcon";
|
|
29
|
+
import XdUnit from "@/components/XdUnit/XdUnit"
|
|
30
|
+
import getServiceUrl from "@/common/getServiceUrl"
|
|
31
|
+
export default {
|
|
32
|
+
components: {
|
|
33
|
+
XdFontIcon,
|
|
34
|
+
XdUnit
|
|
35
|
+
},
|
|
36
|
+
props: {
|
|
37
|
+
list: {
|
|
38
|
+
type: Array,
|
|
39
|
+
default() {
|
|
40
|
+
return []
|
|
41
|
+
}
|
|
42
|
+
},
|
|
43
|
+
vip_card_id: {
|
|
44
|
+
type: Number,
|
|
45
|
+
default: 0
|
|
46
|
+
},
|
|
47
|
+
plus_saving_money: {
|
|
48
|
+
type: Number,
|
|
49
|
+
default: 0
|
|
50
|
+
}
|
|
51
|
+
},
|
|
52
|
+
watch: {
|
|
53
|
+
vip_card_id(val){
|
|
54
|
+
this.vipCardId = val;
|
|
55
|
+
},
|
|
56
|
+
list(val){
|
|
57
|
+
this.uiList = val.map(item => {
|
|
58
|
+
item.vip_card_icon = getServiceUrl(item.vip_card_icon, 'size2');
|
|
59
|
+
return item;
|
|
60
|
+
});
|
|
61
|
+
}
|
|
62
|
+
},
|
|
63
|
+
data(){
|
|
64
|
+
return {
|
|
65
|
+
vipCardId: "",
|
|
66
|
+
uiList: []
|
|
67
|
+
}
|
|
68
|
+
},
|
|
69
|
+
created(){
|
|
70
|
+
this.vipCardId = this.vip_card_id;
|
|
71
|
+
this.uiList = this.list.map(item => {
|
|
72
|
+
item.vip_card_icon = getServiceUrl(item.vip_card_icon, 'size2');
|
|
73
|
+
return item;
|
|
74
|
+
});
|
|
75
|
+
},
|
|
76
|
+
methods: {
|
|
77
|
+
handleChoseVipCard(item){
|
|
78
|
+
if(this.vipCardId === item.vip_card_id){
|
|
79
|
+
this.vipCardId = "";
|
|
80
|
+
}else{
|
|
81
|
+
this.vipCardId = item.vip_card_id;
|
|
82
|
+
}
|
|
83
|
+
this.$emit("choseVipCard", this.vipCardId);
|
|
84
|
+
}
|
|
85
|
+
}
|
|
86
|
+
}
|
|
87
|
+
</script>
|
|
88
|
+
|
|
89
|
+
<style lang="less" scoped>
|
|
90
|
+
.vip-list_wrap{
|
|
91
|
+
padding: 24rpx 0;
|
|
92
|
+
background-color: #FFFFFF;
|
|
93
|
+
.vip_cards-header{
|
|
94
|
+
padding: 0 40rpx 24rpx;
|
|
95
|
+
display: flex;
|
|
96
|
+
align-items: center;
|
|
97
|
+
border-bottom: 2rpx solid #F6F6F6;
|
|
98
|
+
.vip_title{
|
|
99
|
+
color: #86541E;
|
|
100
|
+
font-size: 24rpx;
|
|
101
|
+
font-weight: 400;
|
|
102
|
+
margin-left: 8rpx;
|
|
103
|
+
display: flex;
|
|
104
|
+
align-items: center;
|
|
105
|
+
&-price{
|
|
106
|
+
color: #FF5A39;
|
|
107
|
+
font-weight: bold;
|
|
108
|
+
margin-left: 8rpx;
|
|
109
|
+
}
|
|
110
|
+
}
|
|
111
|
+
}
|
|
112
|
+
.vip_cards-body{
|
|
113
|
+
padding: 24rpx 0 0;
|
|
114
|
+
|
|
115
|
+
.vip_card_list{
|
|
116
|
+
width: 100%;
|
|
117
|
+
overflow: auto;
|
|
118
|
+
white-space: nowrap;
|
|
119
|
+
padding: 0 20rpx;
|
|
120
|
+
box-sizing: border-box;
|
|
121
|
+
|
|
122
|
+
.vip_item{
|
|
123
|
+
width: 160rpx;
|
|
124
|
+
height: 160rpx;
|
|
125
|
+
border: 4rpx solid #EEEEEE;
|
|
126
|
+
background-color: #EEEEEE;
|
|
127
|
+
border-radius: 24rpx;
|
|
128
|
+
box-sizing: border-box;
|
|
129
|
+
display: inline-flex;
|
|
130
|
+
flex-direction: column;
|
|
131
|
+
align-items: center;
|
|
132
|
+
margin: 0 18rpx;
|
|
133
|
+
padding: 16rpx 0;
|
|
134
|
+
color: #999999;
|
|
135
|
+
filter: grayscale(1);
|
|
136
|
+
&.active{
|
|
137
|
+
color: #AB6900;
|
|
138
|
+
border-color: #AB6900;
|
|
139
|
+
background-color: #FFF8ED;
|
|
140
|
+
filter: grayscale(0);
|
|
141
|
+
}
|
|
142
|
+
|
|
143
|
+
.vip_name{
|
|
144
|
+
line-height: 1;
|
|
145
|
+
font-size: 16rpx;
|
|
146
|
+
font-weight: 500;
|
|
147
|
+
}
|
|
148
|
+
.vip_img{
|
|
149
|
+
width: 120rpx;
|
|
150
|
+
height: 60rpx;
|
|
151
|
+
border-radius: 7rpx;
|
|
152
|
+
margin: 8rpx 0;
|
|
153
|
+
display: inline-block;
|
|
154
|
+
box-sizing: border-box;
|
|
155
|
+
image{
|
|
156
|
+
width: 100%;
|
|
157
|
+
height: 100%;
|
|
158
|
+
}
|
|
159
|
+
}
|
|
160
|
+
.vip_price{
|
|
161
|
+
line-height: 1;
|
|
162
|
+
font-size: 36rpx;
|
|
163
|
+
font-weight: 500;
|
|
164
|
+
}
|
|
165
|
+
}
|
|
166
|
+
}
|
|
167
|
+
}
|
|
168
|
+
}
|
|
169
|
+
</style>
|