积分抵扣、霸王餐、优惠券分享新增
This commit is contained in:
@@ -57,7 +57,7 @@
|
||||
teblist: [],
|
||||
myAssetsList: [
|
||||
{ name: "储值", type: "recharge", num: 0, icon: "https://czg-qr-order.oss-cn-beijing.aliyuncs.com/my/storedValue.png"},
|
||||
// { name: "积分", type: "", num: 0, icon: "https://czg-qr-order.oss-cn-beijing.aliyuncs.com/my/points.png"},
|
||||
{ name: "积分", type: "points", num: 0, icon: "https://czg-qr-order.oss-cn-beijing.aliyuncs.com/my/points.png"},
|
||||
{ name: "优惠券", type: "my_coupon", num: 0, icon: "https://czg-qr-order.oss-cn-beijing.aliyuncs.com/my/coupon.png"},
|
||||
// { name: "权益卡", type: "", num: 0, icon: "https://czg-qr-order.oss-cn-beijing.aliyuncs.com/my/equityCard.png"}
|
||||
],
|
||||
@@ -121,6 +121,9 @@
|
||||
if (res.code == 0) {
|
||||
uni.cache.set('userInfo', res.data);
|
||||
this.userInfo = res.data;
|
||||
this.myAssetsList[0].num = res.data.balanceAll || "";
|
||||
this.myAssetsList[1].num = res.data.pointsAll || "";
|
||||
this.myAssetsList[2].num = res.data.couponAll || "";
|
||||
}
|
||||
},
|
||||
|
||||
@@ -180,9 +183,7 @@
|
||||
}
|
||||
switch (item.type) {
|
||||
case 'my_order':
|
||||
uni.switchTab({
|
||||
url: '/pages/order/order'
|
||||
});
|
||||
uni.pro.switchTab('order/order')
|
||||
break
|
||||
case 'my_member':
|
||||
uni.pro.navigateTo('member/list')
|
||||
@@ -200,7 +201,19 @@
|
||||
}
|
||||
|
||||
break
|
||||
case 'my_coupon': //内部页面
|
||||
case 'points': //积分
|
||||
if (uni.cache.get('shopId') && uni.cache.get('token')) {
|
||||
uni.pro.navigateTo('/pagesPoints/index/index', {
|
||||
shopId: uni.cache.get('shopId'),
|
||||
type: 'user',
|
||||
})
|
||||
} else{
|
||||
uni.pro.navigateTo('member/list', {
|
||||
type: 'user_points'
|
||||
})
|
||||
}
|
||||
break;
|
||||
case 'my_coupon': //优惠券
|
||||
uni.pro.navigateTo('user/coupon')
|
||||
break;
|
||||
case 'my_info': //内部页面
|
||||
|
||||
Reference in New Issue
Block a user