diff --git a/app.json b/app.json index 5cf050d..143f44c 100644 --- a/app.json +++ b/app.json @@ -45,12 +45,6 @@ "iconPath": "assets/icon/tabs/tab1.png", "selectedIconPath": "assets/icon/tabs/tab1-active.png" }, - { - "pagePath": "pages/shop/index/index", - "text": "商家", - "iconPath": "assets/icon/tabs/tab2.png", - "selectedIconPath": "assets/icon/tabs/tab2-active.png" - }, { "pagePath": "pages/order/index/index", "text": "订单", diff --git a/pages/my/promation/wx-group/index.js b/pages/my/promation/wx-group/index.js index 5815c85..972ed03 100644 --- a/pages/my/promation/wx-group/index.js +++ b/pages/my/promation/wx-group/index.js @@ -32,7 +32,8 @@ Page({ app.getLocation().then((data)=>{ this.setData({ positioning:false, - positioningError:false + positioningError:false, + isOpenLocation:true }) this.getDetail({latitude:data.latitude,longitude:data.longitude}); }).catch(()=>{ @@ -42,6 +43,7 @@ Page({ positioningError:true }) this.getDetail(); + this.checkSetting(); }) }, getDetail(lnglat){ @@ -52,9 +54,7 @@ Page({ }) }).catch(()=>{ this.setData({ - positioning:false, - qrcodeLoading:false, - positioningError:true + qrcodeLoading:false }) }) }, @@ -69,18 +69,22 @@ Page({ * 生命周期函数--监听页面显示 */ onShow() { + this.getWxGroupQrcode(); + }, + checkSetting(){ wx.getSetting({ success:(res)=>{ const isOpenLocation = res.authSetting['scope.userLocation']; this.setData({ + positioningError:isOpenLocation, isOpenLocation }) if(isOpenLocation){ - this.getWxGroupQrcode(); + // this.getWxGroupQrcode(); }else{ - this.setData({ - positioning:false - }) + // this.setData({ + // positioning:false + // }) } } }) diff --git a/pages/order/index/index.wxml b/pages/order/index/index.wxml index e968837..080d4b4 100644 --- a/pages/order/index/index.wxml +++ b/pages/order/index/index.wxml @@ -1,17 +1,17 @@ - + - +