jufubao-mall 2.0.16-beta54 → 2.0.16-beta56
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
|
@@ -40,7 +40,6 @@
|
|
|
40
40
|
>{{ city.name }}</view>
|
|
41
41
|
</view>
|
|
42
42
|
</view>
|
|
43
|
-
|
|
44
43
|
<view v-if="styleLayout==3 && brandList.length" class="brand_wrap">
|
|
45
44
|
<swiper :style="{height: swiperHeight + 'rpx'}" style="background-color: #FFFFFF;" :indicator-dots="swiperShowDot"
|
|
46
45
|
:indicator-active-color="mainColor"
|
|
@@ -63,23 +62,6 @@
|
|
|
63
62
|
</view>
|
|
64
63
|
<view class="query_filter" :style="[queryFilterStyle]" v-if="showQuery === 'Y'">
|
|
65
64
|
<view v-if="filterItemsComp.length===1">店铺列表</view>
|
|
66
|
-
<!-- <template>
|
|
67
|
-
<view class="query_filter_r" @click="switchQueryModal('city')" v-if="filterModeData.includes('city_code')">
|
|
68
|
-
区域 <xd-font-icon icon="iconxia_down" :size="24" style="margin-left: 4rpx;"></xd-font-icon>
|
|
69
|
-
</view>
|
|
70
|
-
<view class="query_filter_r" @click="switchQueryModal('brand')" v-if="filterModeData.includes('brand_id')">
|
|
71
|
-
品牌 <xd-font-icon icon="iconxia_down" :size="24" style="margin-left: 4rpx;"></xd-font-icon>
|
|
72
|
-
</view>
|
|
73
|
-
<view class="query_filter_r" @click="switchQueryModal('business')" v-if="filterModeData.includes('namespace')">
|
|
74
|
-
业务线 <xd-font-icon icon="iconxia_down" :size="24" style="margin-left: 4rpx;"></xd-font-icon>
|
|
75
|
-
</view>
|
|
76
|
-
<view class="query_filter_r" @click="switchQueryModal('consume_mode')" v-if="filterModeData.includes('consume_mode')">
|
|
77
|
-
门店分类 <xd-font-icon icon="iconxia_down" :size="24" style="margin-left: 4rpx;"></xd-font-icon>
|
|
78
|
-
</view>
|
|
79
|
-
</template>
|
|
80
|
-
<view class="query_filter_r" @click="switchQueryModal('filter')" v-if="filterModeData.includes('filter')">
|
|
81
|
-
筛选 <xd-font-icon icon="icontijianshaixuan" :size="24"></xd-font-icon>
|
|
82
|
-
</view> -->
|
|
83
65
|
<view
|
|
84
66
|
class="query_filter_r"
|
|
85
67
|
v-for="item in filterItemsComp" :key="item.value"
|
|
@@ -509,9 +491,9 @@
|
|
|
509
491
|
//设置业务请求代码
|
|
510
492
|
this.setNameSpace(options);
|
|
511
493
|
console.log(this.xnamespace,'options','mmmmmm')
|
|
512
|
-
if(this.xnamespace){
|
|
513
|
-
|
|
514
|
-
}
|
|
494
|
+
// if(this.xnamespace){
|
|
495
|
+
// this.namespace = this.xnamespace;
|
|
496
|
+
// }
|
|
515
497
|
//地址参数传入过滤条件选中
|
|
516
498
|
if(options['brand_ids']){
|
|
517
499
|
this.$set(this.searchFilterParams, 'brand', options['brand_ids'].split(','));
|
|
@@ -802,10 +784,10 @@
|
|
|
802
784
|
}
|
|
803
785
|
|
|
804
786
|
if(this.dimension==='business'){
|
|
805
|
-
data.
|
|
787
|
+
data.namespaces = this.namespace
|
|
806
788
|
} else {
|
|
807
789
|
//当导航维度是按门店分类时,用category_id承载namespace
|
|
808
|
-
data.
|
|
790
|
+
data.category_ids = this.namespace
|
|
809
791
|
}
|
|
810
792
|
if(this.area_code) data.area_code = this.area_code;
|
|
811
793
|
this.$xdShowLoading({});
|
|
@@ -846,7 +828,7 @@
|
|
|
846
828
|
let params = {
|
|
847
829
|
page_size: this.page_size,
|
|
848
830
|
page_token: this.page_token,
|
|
849
|
-
namespace: this.xnamespace,
|
|
831
|
+
// namespace: this.xnamespace,
|
|
850
832
|
...this.options,
|
|
851
833
|
}
|
|
852
834
|
|
|
@@ -892,11 +874,6 @@
|
|
|
892
874
|
})
|
|
893
875
|
},
|
|
894
876
|
p_getSearchFilter(){
|
|
895
|
-
//未开启过滤条件
|
|
896
|
-
if(this.showQuery === 'N') {
|
|
897
|
-
this.searchFilterList = [];
|
|
898
|
-
return
|
|
899
|
-
}
|
|
900
877
|
return new Promise((resolve, reject) => {
|
|
901
878
|
let data = this.getParams();
|
|
902
879
|
data = {
|
|
@@ -904,36 +881,50 @@
|
|
|
904
881
|
}
|
|
905
882
|
// debugger
|
|
906
883
|
if(this.dimension==='business'){
|
|
907
|
-
data.
|
|
884
|
+
data.namespaces = this.namespace
|
|
908
885
|
} else {
|
|
909
886
|
//当导航维度是按门店分类时,用category_id承载namespace
|
|
910
|
-
data.
|
|
887
|
+
data.category_ids = this.namespace
|
|
911
888
|
}
|
|
912
889
|
jfbRootExec("resourceGetSearchFilters", {
|
|
913
890
|
vm: this,
|
|
914
891
|
data: this.$xdUniHelper.deleteParamEmptyKey(data)
|
|
915
892
|
}).then(res => {
|
|
916
893
|
console.log(res,'res11111')
|
|
917
|
-
|
|
918
|
-
|
|
894
|
+
//未开启过滤条件
|
|
895
|
+
if(this.showQuery === 'N') {
|
|
896
|
+
this.searchFilterList = [];
|
|
897
|
+
}else{
|
|
898
|
+
this.searchFilterList = res.items || [];
|
|
899
|
+
console.log( this.searchFilterList,' this.searchFilterList')
|
|
900
|
+
}
|
|
919
901
|
this.brandList = res.brands.map(item => {
|
|
920
902
|
item.icon = getServiceUrl(item.icon, 'size2');
|
|
921
903
|
return item;
|
|
922
904
|
});
|
|
923
905
|
if(this.showBusinessLine == 'Y'){
|
|
924
|
-
if(this.
|
|
925
|
-
this.
|
|
926
|
-
|
|
927
|
-
|
|
928
|
-
|
|
906
|
+
if(this.namespaceList.length == 0){
|
|
907
|
+
if(this.dimension==='business'){
|
|
908
|
+
this.namespaceList = res.namespaces;
|
|
909
|
+
} else if(this.dimension==='store'){
|
|
910
|
+
//当导航维度是按门店分类时,用categories代替业务线
|
|
911
|
+
this.namespaceList = res.categories;
|
|
912
|
+
}
|
|
913
|
+
if(this.showAllBusinessLine == 'Y'){
|
|
914
|
+
this.namespaceList = [{label: "全部", value: "all"}].concat(this.namespaceList);
|
|
915
|
+
}
|
|
916
|
+
this.namespace = this.namespaceList[0].value;
|
|
917
|
+
console.log(this.namespace,'nnnnn')
|
|
929
918
|
}
|
|
930
919
|
if(this.showAllBusinessLine == 'Y'){
|
|
931
|
-
|
|
920
|
+
let hasAll = this.namespaceList.some(item=>item.value==='all');
|
|
921
|
+
if(!hasAll){
|
|
922
|
+
this.namespaceList = [{label: "全部", value: "all"}].concat(this.namespaceList);
|
|
923
|
+
}
|
|
932
924
|
}else{
|
|
933
|
-
this.namespaceList
|
|
934
|
-
|
|
935
|
-
|
|
936
|
-
this.namespace = this.xnamespace||this.namespaceList[0].value;
|
|
925
|
+
if(this.namespaceList.length){
|
|
926
|
+
this.namespaceList = this.namespaceList.filter(item => item.value!=='all');
|
|
927
|
+
}
|
|
937
928
|
}
|
|
938
929
|
}
|
|
939
930
|
// setTimeout(()=>{
|
|
@@ -1008,6 +999,13 @@
|
|
|
1008
999
|
this.getList();
|
|
1009
1000
|
},
|
|
1010
1001
|
handleSelectNamespace(val){
|
|
1002
|
+
if(this.dimension==='business'){
|
|
1003
|
+
this.category_ids = '';
|
|
1004
|
+
}else if(this.dimension==='store'){
|
|
1005
|
+
this.namespaces = '';
|
|
1006
|
+
}
|
|
1007
|
+
this.searchFilterParams = {};
|
|
1008
|
+
this.searchFilterLabels = {};
|
|
1011
1009
|
this.page_token = 1;
|
|
1012
1010
|
if(this.namespace !== val){
|
|
1013
1011
|
this.namespace = val;
|
|
@@ -10,6 +10,11 @@ module.exports = {
|
|
|
10
10
|
{ label: "电影", value: "movie" },
|
|
11
11
|
{ label: "商城百货1", value: "market" }
|
|
12
12
|
],
|
|
13
|
+
categories:[
|
|
14
|
+
{label: "商超", value: 100518},
|
|
15
|
+
{label: "蛋糕店", value: 100519},
|
|
16
|
+
{label: "电影", value: 200000},
|
|
17
|
+
],
|
|
13
18
|
brands: [
|
|
14
19
|
{
|
|
15
20
|
label: "味多美",
|
|
@@ -352,6 +352,32 @@ export default (data, gValue, gColor, oldData) => {
|
|
|
352
352
|
// {value:'hdSelf', label: '到店取',input:'',check: false,placeholder:'到店取名称,默认“去点餐”'},
|
|
353
353
|
])
|
|
354
354
|
},
|
|
355
|
+
rules:[{
|
|
356
|
+
validator: (rule, value, callback) => {
|
|
357
|
+
let errorStr = '';
|
|
358
|
+
//设置为空
|
|
359
|
+
if(!value || (value && value.length === 0)) {
|
|
360
|
+
callback();
|
|
361
|
+
return;
|
|
362
|
+
}
|
|
363
|
+
//非空,判断设置的名称长度不能大于4
|
|
364
|
+
if(value && value.length > 0) {
|
|
365
|
+
let len = value.length;
|
|
366
|
+
for(let i = 0; i < len; i++) {
|
|
367
|
+
if(value[i].input.length > 4) {
|
|
368
|
+
errorStr = `${value[i].label}名称最大长度不能超过4个汉字`;
|
|
369
|
+
break
|
|
370
|
+
}
|
|
371
|
+
}
|
|
372
|
+
}
|
|
373
|
+
if(errorStr) {
|
|
374
|
+
callback(errorStr)
|
|
375
|
+
return
|
|
376
|
+
}
|
|
377
|
+
|
|
378
|
+
callback()
|
|
379
|
+
}, message: '输入名称内容最多4字', trigger: ['blur', 'change']
|
|
380
|
+
}]
|
|
355
381
|
},
|
|
356
382
|
{ele: 'group_end'},
|
|
357
383
|
{
|