jufubao-mall 2.0.37 → 2.0.39
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/JfbMallCart/JfbMallCart.vue +21 -4
- package/src/components/JfbMallConfirm/JfbMallConfirm.vue +39 -12
- package/src/components/JfbMallConfirm/cusAttr/advanced.js +14 -0
- package/src/components/JfbMallConfirm/cusAttr/style.js +41 -1
- package/src/components/JfbMallNavigation/JfbMallNavigation.vue +7 -1
package/package.json
CHANGED
|
@@ -118,7 +118,8 @@
|
|
|
118
118
|
</view>
|
|
119
119
|
<view class="prod_price">
|
|
120
120
|
<view style="display:flex;align-items:center">
|
|
121
|
-
<xd-unit :price="prod.sale_price" :isOld="false" color="#333" :iconSize="0.3" :fontSize="36"/>
|
|
121
|
+
<!-- <xd-unit :price="prod.sale_price" :isOld="false" color="#333" :iconSize="0.3" :fontSize="36"/> -->
|
|
122
|
+
<CusPrice :iconSize="0.3" :priceSize="36" :showPrice="prod.show_prices"></CusPrice>
|
|
122
123
|
</view>
|
|
123
124
|
<xd-number
|
|
124
125
|
v-if="prod.status === 'ok'"
|
|
@@ -158,9 +159,12 @@
|
|
|
158
159
|
<text class="text ml14">全选</text>
|
|
159
160
|
<text>({{ checkedProdList.length }})</text>
|
|
160
161
|
</view>
|
|
161
|
-
<view
|
|
162
|
-
<
|
|
163
|
-
|
|
162
|
+
<view v-if="!editCart">
|
|
163
|
+
<view class="flex">
|
|
164
|
+
<text class="text">合计:</text>
|
|
165
|
+
<xd-unit :price="calcTotal" :isOld="false"></xd-unit>
|
|
166
|
+
</view>
|
|
167
|
+
<view class="flex save">共省:¥{{ saveTotal }}</view>
|
|
164
168
|
</view>
|
|
165
169
|
</view>
|
|
166
170
|
<xd-button v-if="editCart"
|
|
@@ -205,6 +209,7 @@ import { getContainerPropsValue , toProductDetail, gCPVal} from "@/utils/xd.base
|
|
|
205
209
|
import getServiceUrl from "@/common/getServiceUrl";
|
|
206
210
|
import XdProductStatus from "@/components/XdProductStatus/XdProductStatus";
|
|
207
211
|
import XdNoData from "@/components/XdNoData/XdNoData";
|
|
212
|
+
import CusPrice from '@/components/CusPrice/CusPrice'
|
|
208
213
|
import {mapActions} from "vuex";
|
|
209
214
|
import {getJfbConfig,getColorBaseUrl} from "@/lib/conf.domain";
|
|
210
215
|
import Color from "color"
|
|
@@ -225,6 +230,7 @@ export default {
|
|
|
225
230
|
UniSwipeActionItem,
|
|
226
231
|
XdProductStatus,
|
|
227
232
|
XdNoData,
|
|
233
|
+
CusPrice
|
|
228
234
|
},
|
|
229
235
|
mixins: [componentsMixins, extsMixins, JfbMallCartMixin],
|
|
230
236
|
data() {
|
|
@@ -368,6 +374,12 @@ export default {
|
|
|
368
374
|
return pre + next.num * next.sale_price;
|
|
369
375
|
}, 0);
|
|
370
376
|
},
|
|
377
|
+
//已选商品共省
|
|
378
|
+
saveTotal() {
|
|
379
|
+
return this.checkedProdList.reduce((pre, next) => {
|
|
380
|
+
return pre + next.num * this.$xdUniHelper.divisionFloatNumber(next.diff_price,100)
|
|
381
|
+
}, 0);
|
|
382
|
+
},
|
|
371
383
|
|
|
372
384
|
boxShadow() {
|
|
373
385
|
return this.titleContShadow
|
|
@@ -1113,4 +1125,9 @@ export default {
|
|
|
1113
1125
|
margin-left: 32rpx;
|
|
1114
1126
|
margin-right: 32rpx;
|
|
1115
1127
|
}
|
|
1128
|
+
.save {
|
|
1129
|
+
color: #ff0000;
|
|
1130
|
+
font-size: 24rpx;
|
|
1131
|
+
margin-left: 10rpx;
|
|
1132
|
+
}
|
|
1116
1133
|
</style>
|
|
@@ -121,12 +121,6 @@
|
|
|
121
121
|
<input v-model="comment" class="order_market" :maxlength="50" placeholder="建议留言前先与平台沟通确认,最多只支持50字"/>
|
|
122
122
|
</view>
|
|
123
123
|
<!-- 展示vip -->
|
|
124
|
-
<view v-if="is_show_vip_card_list === 'Y'" class="section" style="overflow: hidden;" :style=[blockSectionStyleComp]>
|
|
125
|
-
<cus-vip-list :list="vipCardList"
|
|
126
|
-
:vip_card_id="vip_card_id"
|
|
127
|
-
:plus_saving_money="orderFee.plus_saving_money"
|
|
128
|
-
@choseVipCard="handleChoseVipCard"></cus-vip-list>
|
|
129
|
-
</view>
|
|
130
124
|
|
|
131
125
|
<!-- 订单费用详情 -->
|
|
132
126
|
<!-- 礼包不显示订单信息 -->
|
|
@@ -141,8 +135,8 @@
|
|
|
141
135
|
</view>
|
|
142
136
|
<view v-if="showPrice === 'Y' || otherPayMethod.filter(it => it.method!=='third').length" class="money_box">
|
|
143
137
|
<template v-if="showPrice === 'Y'">
|
|
144
|
-
<xd-list-item v-if="isShowPlusSavingMoney" label="PLUS
|
|
145
|
-
<view slot="label" style="color: #7F5629;">PLUS
|
|
138
|
+
<xd-list-item v-if="isShowPlusSavingMoney" label="PLUS会员立减" showBottom :paddingLR="isCardLayout ? '32rpx' : '48rpx'">
|
|
139
|
+
<view slot="label" style="color: #7F5629;">PLUS会员立减</view>
|
|
146
140
|
<xd-unit :largeZero="false" :price="-orderFee.plus_saving_money" :isOld="false" :fontSize="28" :iconSize="0.3"></xd-unit>
|
|
147
141
|
</xd-list-item>
|
|
148
142
|
<xd-list-item v-if="showLogisticsDiscount&&main_show_delivery_price==='Y'" label="运费减免" :showBottom="!!showPayMethods.length" :paddingLR="isCardLayout ? '32rpx' : '48rpx'">
|
|
@@ -345,6 +339,13 @@
|
|
|
345
339
|
</template>
|
|
346
340
|
</xd-down-drawer>
|
|
347
341
|
</template>
|
|
342
|
+
<CusVipOpenDialog
|
|
343
|
+
v-if="!isVip"
|
|
344
|
+
:bgImg="openVipBgImg"
|
|
345
|
+
:btnBgImg="openVipBtnBgImg"
|
|
346
|
+
@onOpen="handleOpenVip"
|
|
347
|
+
@onClose="handleCloseOpenVip"
|
|
348
|
+
></CusVipOpenDialog>
|
|
348
349
|
</view>
|
|
349
350
|
</view>
|
|
350
351
|
</template>
|
|
@@ -374,6 +375,7 @@
|
|
|
374
375
|
import XdAddrDefault from "./XdAddrDefault"
|
|
375
376
|
import CusPrice from '@/components/CusPrice/CusPrice'
|
|
376
377
|
import CusVipList from "@/components/CusVipList/CusVipList"
|
|
378
|
+
import CusVipOpenDialog from "@/components/CusVipOpenDialog/CusVipOpenDialog"
|
|
377
379
|
export default {
|
|
378
380
|
// #ifdef MP-WEIXIN
|
|
379
381
|
options: { styleIsolation: 'shared' },
|
|
@@ -396,6 +398,7 @@
|
|
|
396
398
|
XdAddrOld,
|
|
397
399
|
CusPrice,
|
|
398
400
|
CusVipList,
|
|
401
|
+
CusVipOpenDialog
|
|
399
402
|
},
|
|
400
403
|
mixins: [componentsMixins,extsMixins,JfbMallConfirmMixin,OrderMixin],
|
|
401
404
|
data() {
|
|
@@ -534,7 +537,10 @@
|
|
|
534
537
|
showLogisticsTip: "Y",
|
|
535
538
|
logisticsTipText: "",
|
|
536
539
|
checkPayMethod: [],
|
|
537
|
-
ticketPositionStatus: "N"
|
|
540
|
+
ticketPositionStatus: "N",
|
|
541
|
+
openVipBtnBgImg: "",
|
|
542
|
+
openVipBgImg: "",
|
|
543
|
+
openVipPath: ""
|
|
538
544
|
}
|
|
539
545
|
},
|
|
540
546
|
computed: {
|
|
@@ -765,7 +771,10 @@
|
|
|
765
771
|
this.isPreview = this.$configProject['isPreview'];
|
|
766
772
|
this.is_plus_site = this.projectAttr.headers['X-Site-Group']==="vip";
|
|
767
773
|
this.init(this.container);
|
|
768
|
-
this.isVip = this.getTokenForKey('user_level') === 'VIP';
|
|
774
|
+
this.isVip = this.getTokenForKey('user_level') && this.getTokenForKey('user_level') === 'VIP' ? true : false;
|
|
775
|
+
if (this.$configProject['isPreview']) {
|
|
776
|
+
this.isVip=true
|
|
777
|
+
}
|
|
769
778
|
console.log("this.isVip", this.isVip);
|
|
770
779
|
},
|
|
771
780
|
methods: {
|
|
@@ -882,7 +891,13 @@
|
|
|
882
891
|
this.coupon_layout = gCPVal(container, 'coupon_layout', ['1']);
|
|
883
892
|
this.checkPayMethod = gCPVal(container, 'checkPayMethod', []);
|
|
884
893
|
console.log("this.checkPayMethod", this.checkPayMethod);
|
|
885
|
-
|
|
894
|
+
this.openVipBgImg = getServiceUrl(
|
|
895
|
+
getContainerPropsValue(container, "content.openVipBgImg", { url: "" }).url,
|
|
896
|
+
);
|
|
897
|
+
this.openVipBtnBgImg = getServiceUrl(
|
|
898
|
+
getContainerPropsValue(container, "content.openVipBtnBgImg", { url: "" }).url
|
|
899
|
+
);
|
|
900
|
+
this.openVipPath = getContainerPropsValue(container, "content.openVipPath", { value: "" }).value;
|
|
886
901
|
if(this.skipToPay === 'N'){
|
|
887
902
|
this.hasAlertCardChose = true;
|
|
888
903
|
}
|
|
@@ -1490,7 +1505,7 @@
|
|
|
1490
1505
|
}
|
|
1491
1506
|
}
|
|
1492
1507
|
if(this.is_show_vip_card_list === 'Y' && !this.vipCardList.length){
|
|
1493
|
-
this.p_getVipList();
|
|
1508
|
+
// this.p_getVipList();
|
|
1494
1509
|
}
|
|
1495
1510
|
|
|
1496
1511
|
},
|
|
@@ -1559,9 +1574,21 @@
|
|
|
1559
1574
|
})
|
|
1560
1575
|
this.p_getCartConfirm();
|
|
1561
1576
|
},
|
|
1577
|
+
handleCloseOpenVip() {
|
|
1578
|
+
this.$xdUniHelper.navigateBack()
|
|
1579
|
+
},
|
|
1580
|
+
handleOpenVip() {
|
|
1581
|
+
this.$xdUniHelper.navigateTo({
|
|
1582
|
+
url: this.openVipPath
|
|
1583
|
+
})
|
|
1584
|
+
},
|
|
1562
1585
|
|
|
1563
1586
|
onJfbShow(options) {
|
|
1564
1587
|
console.log('event.onJfbShow', options)
|
|
1588
|
+
this.isVip = this.getTokenForKey('user_level') && this.getTokenForKey('user_level') === 'VIP' ? true : false;
|
|
1589
|
+
if (this.$configProject['isPreview']) {
|
|
1590
|
+
this.isVip=true
|
|
1591
|
+
}
|
|
1565
1592
|
this.p_getAddrList();
|
|
1566
1593
|
this.p_getCacheAddrList()
|
|
1567
1594
|
},
|
|
@@ -2,6 +2,7 @@
|
|
|
2
2
|
|
|
3
3
|
export default (data)=>{
|
|
4
4
|
return [
|
|
5
|
+
|
|
5
6
|
{
|
|
6
7
|
label: '收货地址',
|
|
7
8
|
ele: 'xd-select-pages-path',
|
|
@@ -54,6 +55,19 @@ export default (data)=>{
|
|
|
54
55
|
groupKey:'advanced',
|
|
55
56
|
className: 'input100',
|
|
56
57
|
},
|
|
58
|
+
{
|
|
59
|
+
label: '开通会员',
|
|
60
|
+
ele: 'xd-select-pages-path',
|
|
61
|
+
valueKey: 'openVipPath',
|
|
62
|
+
placeholder: '选择开通会员路径',
|
|
63
|
+
value: data.openVipPath || null,
|
|
64
|
+
labelInline: true,
|
|
65
|
+
setting: {
|
|
66
|
+
router: XdBus.getParentApi('getPagesTree'),
|
|
67
|
+
},
|
|
68
|
+
groupKey: 'advanced',
|
|
69
|
+
className: 'input100',
|
|
70
|
+
},
|
|
57
71
|
{
|
|
58
72
|
label: "预览模式",
|
|
59
73
|
ele: "xd-radio",
|
|
@@ -623,6 +623,46 @@ export default function (data={},gValue={},gColor={},oldData) {
|
|
|
623
623
|
showAlpha: true
|
|
624
624
|
},
|
|
625
625
|
},
|
|
626
|
-
{ele: "group_end"},
|
|
626
|
+
{ ele: "group_end" },
|
|
627
|
+
{
|
|
628
|
+
label: "开通PLUS背景图",
|
|
629
|
+
ele: 'xd-upload',
|
|
630
|
+
valueKey: "openVipBgImg",
|
|
631
|
+
groupKey: "style",
|
|
632
|
+
value: data.openVipBgImg || {},
|
|
633
|
+
defaultValue: data.openVipBgImg || null,
|
|
634
|
+
slot: true,
|
|
635
|
+
oneWidth: 355,
|
|
636
|
+
oneHeight: 355,
|
|
637
|
+
elinputClassName: 'input40',
|
|
638
|
+
tipsformet: '上传文件格式:@imageType@,不超过@size@MB.建议宽度为<span style="color:red">710px</span>,高度为<span style="color:red">710px</span>',
|
|
639
|
+
type: ['jpg', 'png', 'jpeg'],
|
|
640
|
+
styleType: 'one',
|
|
641
|
+
uploadType: 'aliyun',
|
|
642
|
+
size: 5,
|
|
643
|
+
action: 'action',
|
|
644
|
+
sort: true,
|
|
645
|
+
maxlen: 100,
|
|
646
|
+
},
|
|
647
|
+
{
|
|
648
|
+
label: "开通PLUS按钮背景图",
|
|
649
|
+
ele: 'xd-upload',
|
|
650
|
+
valueKey: "openVipBtnBgImg",
|
|
651
|
+
groupKey: "style",
|
|
652
|
+
value: data.openVipBtnBgImg || {},
|
|
653
|
+
defaultValue: data.openVipBtnBgImg || null,
|
|
654
|
+
slot: true,
|
|
655
|
+
oneWidth: 223,
|
|
656
|
+
oneHeight: 44,
|
|
657
|
+
elinputClassName: 'input40',
|
|
658
|
+
tipsformet: '上传文件格式:@imageType@,不超过@size@MB.建议宽度为<span style="color:red">446px</span>,宽度为<span style="color:red">88px</span>',
|
|
659
|
+
type: ['jpg', 'png', 'jpeg'],
|
|
660
|
+
styleType: 'one',
|
|
661
|
+
uploadType: 'aliyun',
|
|
662
|
+
size: 5,
|
|
663
|
+
action: 'action',
|
|
664
|
+
sort: true,
|
|
665
|
+
maxlen: 100,
|
|
666
|
+
},
|
|
627
667
|
]
|
|
628
668
|
}
|
|
@@ -454,7 +454,13 @@
|
|
|
454
454
|
if(this.isCurSite(app)){
|
|
455
455
|
value = rData.all.app.value;
|
|
456
456
|
}else{
|
|
457
|
-
|
|
457
|
+
let appValue = rData.all.app.value;
|
|
458
|
+
//appValue是否以@site_domain@开头
|
|
459
|
+
if(appValue.indexOf('@site_domain@') === 0){
|
|
460
|
+
value = appValue;
|
|
461
|
+
}else{
|
|
462
|
+
value = `@site_domain@/${app.dir}` + appValue;
|
|
463
|
+
}
|
|
458
464
|
}
|
|
459
465
|
// #endif
|
|
460
466
|
|