jufubao-mall 2.0.3 → 2.0.5-beta1
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
CHANGED
|
@@ -311,6 +311,11 @@
|
|
|
311
311
|
:layoutInfo="layoutInfo"
|
|
312
312
|
:fixedStyle="fixedStyle"
|
|
313
313
|
:mainColor="mainColor"
|
|
314
|
+
:salePriceColor="salePriceColor"
|
|
315
|
+
:salePriceFontSize="salePriceFontSize"
|
|
316
|
+
:originalPriceFontSize="originalPriceFontSize"
|
|
317
|
+
:originalPriceColor="originalPriceColor"
|
|
318
|
+
:isPlus="is_plus_site"
|
|
314
319
|
@change="handleSkuChange"
|
|
315
320
|
@onConfirm="handleConfirmSku"
|
|
316
321
|
></xd-sku>
|
|
@@ -972,7 +977,7 @@
|
|
|
972
977
|
NORMAL: {
|
|
973
978
|
WITH_DISCOUNT: [
|
|
974
979
|
{ p: 2678, n: "PLUS价", t: "S" },
|
|
975
|
-
{ p: 4000, n: "原价", t: "U" }
|
|
980
|
+
{ p: 4000, n: "原价", t: "U" },
|
|
976
981
|
],
|
|
977
982
|
WITHOUT_DISCOUNT: [
|
|
978
983
|
{ p: 2678, n: "PLUS价", t: "S" }
|
|
@@ -12,7 +12,7 @@
|
|
|
12
12
|
<view id="prod_wrap" class="prod_wrap">
|
|
13
13
|
<image class="sku_img" :src="skuImage" />
|
|
14
14
|
<view class="sku_info">
|
|
15
|
-
<
|
|
15
|
+
<CusPrice :key="priceNew" v-if="priceNew" :salePriceColor="salePriceColor" :salePriceFontSize="salePriceFontSize" :originalPriceFontSize="originalPriceFontSize" :originalPriceColor="originalPriceColor" :isPlus="is_plus_site" iconSize="0.4" :showPrice="priceNew" type="info"></CusPrice>
|
|
16
16
|
<view v-if="choseSkuName" class="_specs"
|
|
17
17
|
>已选:{{ choseSkuName }}</view
|
|
18
18
|
>
|
|
@@ -196,6 +196,7 @@ import XdNumber from "@/components/XdNumber/XdNumber";
|
|
|
196
196
|
import XdButton from "@/components/XdButton/XdButton";
|
|
197
197
|
import XdUnit from "@/components/XdUnit/XdUnit";
|
|
198
198
|
import XdFontIcon from "@/components/XdFontIcon/XdFontIcon";
|
|
199
|
+
import CusPrice from '@/components/CusPrice/CusPrice'
|
|
199
200
|
import Color from "color";
|
|
200
201
|
import getServiceUrl from "@/common/getServiceUrl";
|
|
201
202
|
import {
|
|
@@ -212,6 +213,7 @@ export default {
|
|
|
212
213
|
XdButton,
|
|
213
214
|
XdUnit,
|
|
214
215
|
XdFontIcon,
|
|
216
|
+
CusPrice
|
|
215
217
|
},
|
|
216
218
|
props: {
|
|
217
219
|
action: {
|
|
@@ -271,7 +273,28 @@ export default {
|
|
|
271
273
|
initStatus: {
|
|
272
274
|
type: Boolean,
|
|
273
275
|
default:false
|
|
276
|
+
},
|
|
277
|
+
salePriceColor: {
|
|
278
|
+
type: String,
|
|
279
|
+
default: "",
|
|
280
|
+
},
|
|
281
|
+
salePriceFontSize: {
|
|
282
|
+
type: String,
|
|
283
|
+
default: "",
|
|
284
|
+
},
|
|
285
|
+
originalPriceFontSize: {
|
|
286
|
+
type: String,
|
|
287
|
+
default: "",
|
|
288
|
+
},
|
|
289
|
+
originalPriceColor: {
|
|
290
|
+
type: String,
|
|
291
|
+
default: "",
|
|
292
|
+
},
|
|
293
|
+
is_plus_site: {
|
|
294
|
+
type: Boolean,
|
|
295
|
+
default: false,
|
|
274
296
|
}
|
|
297
|
+
|
|
275
298
|
},
|
|
276
299
|
data() {
|
|
277
300
|
return {
|
|
@@ -358,30 +381,23 @@ export default {
|
|
|
358
381
|
return this.buyButton.buttons.find((item) => item.code === "buy-now");
|
|
359
382
|
},
|
|
360
383
|
priceNew() {
|
|
361
|
-
let prices =
|
|
362
|
-
|
|
363
|
-
|
|
364
|
-
|
|
365
|
-
|
|
366
|
-
|
|
367
|
-
|
|
368
|
-
} else {
|
|
369
|
-
if (this.baseInfo&&this.baseInfo.prices) {
|
|
370
|
-
prices = this.baseInfo.prices;
|
|
384
|
+
let prices = null;
|
|
385
|
+
if (
|
|
386
|
+
this.currSku &&
|
|
387
|
+
this.currSku.prices &&
|
|
388
|
+
this.currSku.prices.show_prices
|
|
389
|
+
) {
|
|
390
|
+
prices = this.currSku.prices.show_prices
|
|
371
391
|
} else {
|
|
372
|
-
prices
|
|
392
|
+
if (this.baseInfo && this.baseInfo.prices && this.baseInfo.prices.show_prices) {
|
|
393
|
+
prices = this.baseInfo.prices.show_prices
|
|
394
|
+
} else {
|
|
395
|
+
prices = []
|
|
396
|
+
}
|
|
373
397
|
}
|
|
374
|
-
|
|
375
|
-
|
|
376
|
-
|
|
377
|
-
prices = {};
|
|
378
|
-
}
|
|
379
|
-
if (!prices.show_prices) {
|
|
380
|
-
prices.show_prices = [];
|
|
381
|
-
}
|
|
382
|
-
const filteredPrice = prices.show_prices.find((item) => item.t === "S");
|
|
383
|
-
return filteredPrice || {};
|
|
384
|
-
},
|
|
398
|
+
return prices
|
|
399
|
+
},
|
|
400
|
+
|
|
385
401
|
},
|
|
386
402
|
async created() {
|
|
387
403
|
this.style = await getParentsStyles(this.$parent);
|
|
@@ -18,7 +18,7 @@
|
|
|
18
18
|
class="tab_item"
|
|
19
19
|
v-for="(item,index) in titleList"
|
|
20
20
|
:key="index"
|
|
21
|
-
:class="{
|
|
21
|
+
:class="{short: tabLayout === 'v2'}"
|
|
22
22
|
@click="tab=item.value"
|
|
23
23
|
:style="[tab === item.value?tabActItemStyleComp:tabItemStyleComp]"
|
|
24
24
|
>
|
|
@@ -41,23 +41,25 @@
|
|
|
41
41
|
></xd-baidu-map>
|
|
42
42
|
<!--#endif-->
|
|
43
43
|
<!-- #ifdef MP-WEIXIN -->
|
|
44
|
-
<map
|
|
45
|
-
|
|
46
|
-
|
|
47
|
-
|
|
48
|
-
|
|
49
|
-
|
|
44
|
+
<map
|
|
45
|
+
style="width:100%;height: 100%;"
|
|
46
|
+
show-location
|
|
47
|
+
:longitude="mapCenter.longitude"
|
|
48
|
+
:latitude="mapCenter.latitude"
|
|
49
|
+
:markers="marketList"
|
|
50
|
+
@markertap="handleMarketTap"
|
|
50
51
|
>
|
|
51
52
|
<cover-view
|
|
52
53
|
class="cover_view"
|
|
53
54
|
slot="callout"
|
|
54
55
|
>
|
|
55
|
-
<cover-view
|
|
56
|
-
|
|
57
|
-
|
|
58
|
-
|
|
59
|
-
|
|
60
|
-
|
|
56
|
+
<cover-view
|
|
57
|
+
v-for="(item,index) in marketList"
|
|
58
|
+
:key="index"
|
|
59
|
+
:marker-id="item.id"
|
|
60
|
+
style="background: rgba(0,0,0,.8);border-radius: 20px;padding: 4px 8px;color: #FFFFFF;"
|
|
61
|
+
:style="{display: item.id === showMarkerId ? 'block' : 'none'}"
|
|
62
|
+
>{{ item.title }}</cover-view>
|
|
61
63
|
</cover-view>
|
|
62
64
|
</map>
|
|
63
65
|
<!-- #endif -->
|
|
@@ -245,11 +247,11 @@
|
|
|
245
247
|
}
|
|
246
248
|
},
|
|
247
249
|
tabsStyleComp() {
|
|
248
|
-
let padding = 0, height = '100rpx';
|
|
250
|
+
let padding = '0 24rpx', height = '100rpx';
|
|
249
251
|
if(this.tabLayout === 'v3') {
|
|
250
|
-
padding = '
|
|
252
|
+
padding = '20rpx 24rpx'
|
|
251
253
|
if(this.titleList.length === 1) padding = '16rpx 0'
|
|
252
|
-
height = '
|
|
254
|
+
height = '60rpx';
|
|
253
255
|
}
|
|
254
256
|
return {
|
|
255
257
|
padding,
|
|
@@ -269,7 +271,7 @@
|
|
|
269
271
|
}
|
|
270
272
|
},
|
|
271
273
|
contStyleComp(){
|
|
272
|
-
let height = this.layoutInfo.bodyMinHeightRpx -
|
|
274
|
+
let height = this.layoutInfo.bodyMinHeightRpx - 100 - 72;
|
|
273
275
|
if(this.mapIsExtend) height = height - 400;
|
|
274
276
|
height = height - this.getPMValue(this.bodyPadding, 'TB', 0);
|
|
275
277
|
return {
|
|
@@ -311,7 +313,7 @@
|
|
|
311
313
|
},
|
|
312
314
|
methods: {
|
|
313
315
|
onJfbLoad(options) {
|
|
314
|
-
this.setNameSpace(options);
|
|
316
|
+
this.setNameSpace(options, false);
|
|
315
317
|
this.uiBaiduAk = this.baiduAk || this.$settings.baiduAk;
|
|
316
318
|
this.myPosition = {
|
|
317
319
|
lng: this.stateLocation.longitude,
|
|
@@ -730,30 +732,19 @@
|
|
|
730
732
|
font-size: 32rpx;
|
|
731
733
|
color: #333;
|
|
732
734
|
font-weight: 400;
|
|
733
|
-
padding: 0
|
|
735
|
+
padding: 0 24rpx;
|
|
734
736
|
position: relative;
|
|
735
737
|
border-radius: 60rpx;
|
|
736
738
|
|
|
737
739
|
& .lineX {
|
|
738
740
|
position: absolute;
|
|
739
741
|
bottom: 14rpx;
|
|
740
|
-
height:
|
|
742
|
+
height: 6rpx;
|
|
741
743
|
background-color: var(--main-color);
|
|
742
744
|
border-radius: 6rpx;
|
|
743
|
-
|
|
744
|
-
|
|
745
|
-
|
|
746
|
-
& .lineX {
|
|
747
|
-
left: 40rpx;
|
|
748
|
-
right: 40rpx;;
|
|
749
|
-
|
|
750
|
-
}
|
|
751
|
-
}
|
|
752
|
-
&.short {
|
|
753
|
-
& .lineX {
|
|
754
|
-
left: 80rpx;
|
|
755
|
-
right: 80rpx;;
|
|
756
|
-
}
|
|
745
|
+
width: 64rpx;
|
|
746
|
+
left: 50%;
|
|
747
|
+
transform: translateX(-50%);
|
|
757
748
|
}
|
|
758
749
|
}
|
|
759
750
|
}
|