jufubao-mall 2.0.31-beta102 → 2.0.31-beta104

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
@@ -1,6 +1,6 @@
1
1
  {
2
2
  "name": "jufubao-mall",
3
- "version": "2.0.31-beta102",
3
+ "version": "2.0.31-beta104",
4
4
  "private": false,
5
5
  "description": "聚福宝商城业务组件插件包",
6
6
  "main": "index.js",
@@ -51,11 +51,14 @@
51
51
  >
52
52
  <view class="product_scroll_inner" :style="rightNavStyleComp">
53
53
  <view v-if="!hasTop" style="height: 24rpx;"></view>
54
- <view class="product_group" v-for="cate in categoryList" :key="cate.category_id"
54
+ <view class="product_group" v-for="(cate, index) in categoryList" :key="cate.category_id"
55
55
  :id="getID(cate)"
56
56
  :data-next="cate.nextHeight"
57
57
  >
58
- <view v-if="cate.navigation && cate.navigation.ad_image_url" class="group_ad" @click="handleAdClick(cate)">
58
+ <view v-if="$configProject['isPreview'] && index===0" class="group_ad">
59
+ <image mode="widthFix" src="https://sandbox-img.jufubao.cn/uploads/20251209/3a84bbc1f93fa3b41f62b2c04a83a2c4.png?x-oss-process=style/size3&ver=1766743768"></image>
60
+ </view>
61
+ <view v-else-if="cate.navigation && cate.navigation.ad_image_url" class="group_ad" @click="handleAdClick(cate)">
59
62
  <image mode="widthFix" :src="getServiceUrl(cate.navigation.ad_image_url)"></image>
60
63
  </view>
61
64
  <view v-else class="group_title">{{cate.category_name}}</view>
@@ -78,7 +81,7 @@
78
81
  </view>
79
82
  </view>
80
83
  <view v-else>
81
- <xd-no-data>暂无数据</xd-no-data>
84
+ <xd-no-data :scaleSize="2">暂无数据</xd-no-data>
82
85
  </view>
83
86
  </view>
84
87
  </view>
@@ -210,10 +213,7 @@
210
213
  let itemWidth = this.rightNavImgSize;
211
214
  return {
212
215
  width: itemWidth + 'rpx',
213
- borderRadius: this.rightNavItemRadius + 'rpx',
214
- border: this.getBorderCompatibleOldStyle(this.rightNavItemBorder, {}),
215
- boxShadow: this.rightNavItemShadow,
216
- backgroundColor: this.rightNavItemBGColor,
216
+
217
217
  }
218
218
  },
219
219
  rightNavItemImgStyleComp(){
@@ -221,7 +221,11 @@
221
221
  let imgW = itemWidth - this.rightNavItemPadding * 2;
222
222
  return {
223
223
  width: imgW + 'rpx',
224
- height: imgW + 'rpx'
224
+ height: imgW + 'rpx',
225
+ borderRadius: this.rightNavItemRadius + 'rpx',
226
+ backgroundColor: this.rightNavItemBGColor,
227
+ boxShadow: this.rightNavItemShadow,
228
+ border: this.getBorderCompatibleOldStyle(this.rightNavItemBorder, {}),
225
229
  }
226
230
  },
227
231
  rightNavItemNameStyleComp(){
@@ -309,7 +313,7 @@
309
313
  this.template_id = gCPVal(container, 'template_id', '');
310
314
  this.bodyPadding = gCPVal(container,'bodyPadding', [0], {sKey:'bodyPaddingStatus',fields:['bodyPadding'],isPMR: true});
311
315
  this.navTopMargin = gCPVal(container,'navTopMargin', [0], {sKey:'navTopMarginStatus',fields:['navTopMargin'],isPMR: true});
312
- this.navTopPadding = gCPVal(container,'navTopPadding', [{top: 16,left: 24, bottom: 16, right: 24}], {sKey:'navTopPaddingStatus',isPMR: true});
316
+ this.navTopPadding = gCPVal(container,'navTopPadding', [{top: 16,left: 12, bottom: 16, right: 12}], {sKey:'navTopPaddingStatus',isPMR: true});
313
317
  this.navTopBg = gCPVal(container,'navTopBg', '#FFFFFF', {sKey:'navTopBgStatus'});
314
318
  this.navTopImgSize = gCPVal(container,'navTopImgSize', 120, {sKey:'navTopImgSizeStatus'});
315
319
  this.navTopItemPadding = gCPVal(container,'navTopItemPadding', 0, {sKey:'navTopItemPaddingStatus'});
@@ -336,7 +340,7 @@
336
340
  this.rightNavItemBGColor = gCPVal(container, 'rightNavItemBGColor', '#FFFFFF', {sKey:'rightNavItemBGColorStatus'});
337
341
  this.rightNavItemShadow = gCPVal(container, 'rightNavItemShadow', {color: '#eee',width: '0'}, {isShadow: true});
338
342
  this.rightNavItemBorder = gCPVal(container, 'rightNavItemBorder', {});
339
- this.rightNavItemRadius = gCPVal(container,'rightNavItemRadius', 0, {sKey:'rightNavItemRadiusStatus'});
343
+ this.rightNavItemRadius = gCPVal(container,'rightNavItemRadius', 16, {sKey:'rightNavItemRadiusStatus'});
340
344
  this.rightNavItemFontColor = gCPVal(container,'rightNavItemFontColor', '#666666', {sKey:'rightNavItemFontStatus', fields: ['rightNavItemFontSize', 'rightNavItemFontColor']});
341
345
  this.rightNavItemFontSize = gCPVal(container,'rightNavItemFontSize', 24, {sKey:'rightNavItemFontStatus', fields: ['rightNavItemFontSize', 'rightNavItemFontColor']});
342
346
  console.log("this.rightNavItemFontSize", this.rightNavItemFontSize);
@@ -379,9 +383,12 @@
379
383
  handleToDetail(sub, parent){
380
384
  console.log('handleToDetail', sub, parent);
381
385
  let navObj = parent.navigation;
386
+ let extParams = {};
387
+ if(navObj.business_code) extParams.xnamespace = navObj.business_code;
382
388
  if(navObj.data_source === 'product_category'){
383
389
  //商品分类
384
- this.handleLink(navObj.redirect_type, navObj.redirect_data, {category_id: sub.id});
390
+ extParams.category_id = sub.id;
391
+ this.handleLink(navObj.redirect_type, navObj.redirect_data, extParams);
385
392
  }else if(navObj.data_source === 'product_brand'){
386
393
  //品牌
387
394
  let redirect_type, redirect_data;
@@ -398,18 +405,24 @@
398
405
  redirect_type = navObj.offline_redirect_type;
399
406
  redirect_data = navObj.offline_redirect_data;
400
407
  }
401
- this.handleLink(redirect_type, redirect_data, {brand_id: sub.id});
408
+ extParams.brand_id = sub.id;
409
+ if(navObj.data_json && navObj.data_json.brand_type) extParams.brand_type = navObj.data_json.brand_type;
410
+ this.handleLink(redirect_type, redirect_data, extParams);
402
411
  }else if(navObj.data_source === 'custom'){
403
412
  //自定义
404
- this.handleLink(sub.redirect_type, sub.redirect_data);
413
+ this.handleLink(sub.redirect_type, sub.redirect_data, extParams);
405
414
  }
406
415
  },
407
416
  handleAdClick(parent){
408
417
  let navObj = parent.navigation;
409
- this.handleLink(navObj.redirect_type, navObj.redirect_data);
418
+ let extParams = {};
419
+ if(navObj.business_code) extParams.xnamespace = navObj.business_code;
420
+ this.handleLink(navObj.ad_redirect_type, navObj.ad_redirect_data, extParams);
410
421
  },
411
422
  handleTopClick(item){
412
- this.handleLink(item.redirect_type, item.redirect_data)
423
+ let extParams = {};
424
+ if(item.business_code) extParams.xnamespace = item.business_code;
425
+ this.handleLink(item.redirect_type, item.redirect_data, extParams);
413
426
  },
414
427
  handleLink(redirect_type, redirect_data, otherParams = {}){
415
428
  var item = {redirect_type};
@@ -420,6 +433,27 @@
420
433
  let app_code = rData.all.app.aopen_app_code;
421
434
  let app_type= rData.all.app.appType;
422
435
  let rParams = rData.params || {};
436
+
437
+ for(let key in rParams){
438
+ if(Array.isArray(rParams[key])){
439
+ let cur = rParams[key];
440
+ let pStr = "";
441
+ for(let iKey in cur){
442
+ if(typeof cur[iKey] === 'string' || typeof cur[iKey] === 'number'){
443
+ pStr += `,${cur[iKey]}`;
444
+ }else if(typeof cur[iKey] === 'object' && cur[iKey].value){
445
+ pStr += `,${cur[iKey].value}`;
446
+ }
447
+ }
448
+ rParams[key] = pStr.substring(1);
449
+ }
450
+ if(typeof rParams[key] === 'object'){
451
+ if(rParams[key].value){
452
+ rParams[key] = rParams[key].value;
453
+ }
454
+ }
455
+ }
456
+
423
457
  let customParams = rData.customParams || "";
424
458
  let redirectData = {
425
459
  page: value,
@@ -509,15 +543,16 @@
509
543
  this.cateIndex = index;
510
544
  this.loadCateIndex = index;
511
545
  let curCate = this.categoryList[index];
512
- this.prodScrollIntoView = this.getID(curCate);
546
+
513
547
  //是否最后一个分类
514
548
  if(this.cateIndex === this.categoryList.length - 1){
515
549
  await this.loadPreCateProduct(index);
516
550
  }
517
551
  //当前分类未加载过,则加载当前分类数据
518
552
  if(!curCate.loaded){
519
- this.p_getSubCateList();
553
+ await this.p_getSubCateList();
520
554
  }
555
+ this.prodScrollIntoView = this.getID(curCate);
521
556
  setTimeout(()=>{
522
557
  this.pointerScroll = true;
523
558
  }, 500)
@@ -703,6 +738,11 @@
703
738
  },
704
739
  onJfbShow(options) {
705
740
  console.log('event.onJfbShow', options)
741
+ // this.categoryList = [];
742
+ // this.cateIndex = 0;
743
+ // this.loadCateIndex = 0;
744
+ // this.pointerScroll = true;
745
+ // this.onJfbLoad(options);
706
746
  },
707
747
  onJfbHide(options) {
708
748
  console.log('event.onJfbHide', options)
@@ -729,19 +769,19 @@
729
769
  box-sizing: border-box;
730
770
  .nav_top{
731
771
  background-color: #FFFFFF;
732
- padding: 16rpx 24rpx;
772
+ padding: 16rpx 12rpx;
733
773
  .cate_item{
734
- margin: 8rpx 22rpx 8rpx 0;
735
- &:nth-child(5n){
736
- margin-right: 0;
737
- }
774
+ margin: 8rpx 12rpx;
775
+ // &:nth-child(5n){
776
+ // margin-right: 0;
777
+ // }
738
778
  }
739
779
  }
740
780
  .nav_main{
741
781
  display: flex;
742
782
  box-sizing: border-box;
743
783
  .left_nav{
744
- width: 160rpx;
784
+ width: 152rpx;
745
785
  background-color: #F8F8F8;
746
786
  font-size: 24rpx;
747
787
  color: #333333;
@@ -793,10 +833,17 @@
793
833
  }
794
834
  .group_ad{
795
835
  width: 100%;
836
+ border-radius: 16rpx 16rpx 0 0;
837
+ overflow: hidden;
796
838
  image{
797
839
  width: 100%;
798
840
  display: block;
799
841
  }
842
+
843
+ & + .product_list{
844
+ border-top-left-radius: 0;
845
+ border-top-right-radius: 0;
846
+ }
800
847
  }
801
848
  .product_list{
802
849
  background: #FFFFFF;
@@ -812,12 +859,13 @@
812
859
  }
813
860
  }
814
861
  .cate_item{
815
- margin: 20rpx 28rpx;
816
- &:nth-child(3n){
817
- margin-right: 0;
818
- }
862
+ margin: 20rpx 26rpx;
863
+ // &:nth-child(3n){
864
+ // margin-right: 0;
865
+ // }
819
866
  .cate_img{
820
867
  box-shadow: 0 0 6rpx rgba(0, 0, 0, 0.08);
868
+ border-radius: 16rpx;
821
869
  }
822
870
  .cate_name{
823
871
  margin-top: 10rpx;
@@ -840,6 +888,7 @@
840
888
  align-items: center;
841
889
  padding: 12rpx;
842
890
  box-sizing: border-box;
891
+ overflow: hidden;
843
892
  image{
844
893
  width: 100%;
845
894
  height: 100%;
@@ -2,15 +2,5 @@
2
2
 
3
3
  export default (data)=>{
4
4
  return [
5
-
6
- {
7
- label: '版本号:',
8
- ele: 'el-input',
9
- type: 'text',
10
- groupKey: 'advanced',
11
- valueKey: 'version',
12
- value: 'v2.0',
13
- hidden: true,
14
- },
15
5
  ]
16
6
  }
@@ -95,5 +95,14 @@ export default function (data, gValue,gColor,oldData){
95
95
  });
96
96
  },
97
97
  },
98
+ {
99
+ label: '版本号:',
100
+ ele: 'el-input',
101
+ type: 'text',
102
+ groupKey: 'content',
103
+ valueKey: 'version',
104
+ value: 'v2.0',
105
+ hidden: true,
106
+ },
98
107
  ].filter(i=>i);
99
108
  }
@@ -854,7 +854,7 @@ export default function (data={},gValue={},gColor={},oldData) {
854
854
  ele: 'xd-site-select-list',
855
855
  labelInline: true,
856
856
  valueKey: 'rightNavItemRadius',
857
- value: dataVal({data, key:'rightNavItemRadius', dValue:'10', gValue}),
857
+ value: dataVal({data, key:'rightNavItemRadius', dValue:'16', gValue}),
858
858
  hidden: !statusShow({data, key: 'rightNavItemRadiusStatus', fields:['rightNavItemRadius'], gValue}),
859
859
  placeholder: '请选择图标是否设置圆角',
860
860
  multiple: false,