jufubao-food 1.0.15-beta15 → 1.0.15-beta17
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
|
@@ -116,6 +116,7 @@
|
|
|
116
116
|
consume_mode: "",
|
|
117
117
|
category_id: "",
|
|
118
118
|
specsPrice: 0,
|
|
119
|
+
xnamespace: "",
|
|
119
120
|
|
|
120
121
|
baseInfo: null,
|
|
121
122
|
images: [],
|
|
@@ -222,6 +223,7 @@
|
|
|
222
223
|
* @param container {object} 业务组件对象自己
|
|
223
224
|
*/
|
|
224
225
|
init(container) {
|
|
226
|
+
this.xnamespace = gCPVal(container, 'xnamespace', this.projectAttr.business_code||this.xnamespace);
|
|
225
227
|
this.foodProductListPath = getContainerPropsValue(container, 'content.foodProductListPath', {value: ""}).value;
|
|
226
228
|
this.shopBtnBgColor = gCPVal(container, 'shopBtnBgColor', this.mainColor, {sKey:'cartBtnStatus',fields:['shopBtnBgColor']});
|
|
227
229
|
this.showDiscount = gCPVal(container, 'showDiscount', "Y");
|
|
@@ -200,7 +200,7 @@
|
|
|
200
200
|
</xd-down-drawer>
|
|
201
201
|
<view v-if="showEmptyShop" class="empty_shop">
|
|
202
202
|
<xd-no-data :scaleSize="2" iconType="shop">附近暂无门店</xd-no-data>
|
|
203
|
-
<view class="empty_chose_btn" @click="
|
|
203
|
+
<view class="empty_chose_btn" @click="handleSwitchCity">选择其他城市 <xd-font-icon icon="iconxiangyou_xian" :size="24"></xd-font-icon></view>
|
|
204
204
|
</view>
|
|
205
205
|
</view>
|
|
206
206
|
</view>
|
|
@@ -238,6 +238,7 @@
|
|
|
238
238
|
],
|
|
239
239
|
data() {
|
|
240
240
|
return {
|
|
241
|
+
pageOptions: {},
|
|
241
242
|
closeMask: true,
|
|
242
243
|
isPreview: false,
|
|
243
244
|
resource_shop_id: "",
|
|
@@ -305,6 +306,7 @@
|
|
|
305
306
|
foodDetailPath: "",
|
|
306
307
|
confirmPath: "",
|
|
307
308
|
switchStorePath: "",
|
|
309
|
+
switchCityPath: "",
|
|
308
310
|
}
|
|
309
311
|
},
|
|
310
312
|
computed: {
|
|
@@ -427,6 +429,11 @@
|
|
|
427
429
|
if (JSON.stringify(value) === JSON.stringify(oldValue)) return;
|
|
428
430
|
if (this.$configProject['isPreview']) this.init(value)
|
|
429
431
|
},
|
|
432
|
+
stateCity(n, o) {
|
|
433
|
+
if(n && JSON.stringify(n) !== JSON.stringify(o)){
|
|
434
|
+
this.onJfbLoad(this.pageOptions);
|
|
435
|
+
}
|
|
436
|
+
}
|
|
430
437
|
},
|
|
431
438
|
created() {
|
|
432
439
|
this.init(this.container);
|
|
@@ -436,6 +443,7 @@
|
|
|
436
443
|
},
|
|
437
444
|
methods: {
|
|
438
445
|
onJfbLoad(options) {
|
|
446
|
+
this.pageOptions = options;
|
|
439
447
|
this.setNameSpace(options);
|
|
440
448
|
this.resource_shop_id = options.resource_shop_id;
|
|
441
449
|
this.consume_mode = options.consume_mode || 'HDSELF';
|
|
@@ -459,6 +467,7 @@
|
|
|
459
467
|
this.foodDetailPath = getContainerPropsValue(container, 'content.foodDetailPath', {value: ""}).value;
|
|
460
468
|
this.confirmPath = getContainerPropsValue(container, 'content.confirmPath', {value: ""}).value;
|
|
461
469
|
this.switchStorePath = getContainerPropsValue(container, 'content.switchStorePath', { value: ''}).value;
|
|
470
|
+
this.switchCityPath = getContainerPropsValue(container, 'content.switchCityPath', { value: ''}).value;
|
|
462
471
|
this.showDiscount = gCPVal(container, 'showDiscount', "Y");
|
|
463
472
|
this.differ = gCPVal(container, 'differ', 1);
|
|
464
473
|
|
|
@@ -555,6 +564,11 @@
|
|
|
555
564
|
}
|
|
556
565
|
this.showTakeoutShop = true;
|
|
557
566
|
},
|
|
567
|
+
handleSwitchCity(){
|
|
568
|
+
this.$xdUniHelper.navigateTo({
|
|
569
|
+
url: this.switchCityPath
|
|
570
|
+
})
|
|
571
|
+
},
|
|
558
572
|
handleSwitchShop(){
|
|
559
573
|
//切换门店
|
|
560
574
|
let curPage = this.$xdUniHelper.getCurrentPages();
|
|
@@ -592,6 +606,7 @@
|
|
|
592
606
|
}
|
|
593
607
|
}).then(res => {
|
|
594
608
|
if(res.list && res.list.length > 0){
|
|
609
|
+
this.showEmptyShop = false;
|
|
595
610
|
this.shopList = res.list;
|
|
596
611
|
if(loadFirstShop){
|
|
597
612
|
this.curShopIndex = 0;
|
|
@@ -41,6 +41,19 @@ export default (data)=>{
|
|
|
41
41
|
groupKey:'advanced',
|
|
42
42
|
className: 'input100',
|
|
43
43
|
},
|
|
44
|
+
{
|
|
45
|
+
label: '切换城市',
|
|
46
|
+
ele: 'xd-select-pages-path',
|
|
47
|
+
valueKey: 'switchCityPath',
|
|
48
|
+
placeholder: '请选择切换城市跳转地址',
|
|
49
|
+
value: data.switchCityPath || null,
|
|
50
|
+
setting: {
|
|
51
|
+
router: XdBus.getParentApi('getPagesTree'),
|
|
52
|
+
},
|
|
53
|
+
labelInline: true,
|
|
54
|
+
groupKey:'advanced',
|
|
55
|
+
className: 'input100',
|
|
56
|
+
},
|
|
44
57
|
|
|
45
58
|
{
|
|
46
59
|
label: '版本号:',
|