Commit 6a76ccc0ef07320b0c23e5bf7d8e8d5a2a8d6fdb
1 parent
1de5a132
未登陆不允许分享的优化
Showing
86 changed files
with
175 additions
and
34 deletions
app.js
| @@ -205,6 +205,7 @@ App({ | @@ -205,6 +205,7 @@ App({ | ||
| 205 | this.getConfig(); | 205 | this.getConfig(); |
| 206 | }, | 206 | }, |
| 207 | 207 | ||
| 208 | + | ||
| 208 | //---初始化第三方---- | 209 | //---初始化第三方---- |
| 209 | initExt: function () { | 210 | initExt: function () { |
| 210 | var tt = t; | 211 | var tt = t; |
| @@ -842,7 +843,6 @@ App({ | @@ -842,7 +843,6 @@ App({ | ||
| 842 | urls: [path] | 843 | urls: [path] |
| 843 | }); | 844 | }); |
| 844 | }, | 845 | }, |
| 845 | - | ||
| 846 | //b是数组,t是wxml元素返回的 | 846 | //b是数组,t是wxml元素返回的 |
| 847 | pre_img2(b,t){ | 847 | pre_img2(b,t){ |
| 848 | this.globalData.no_clear=1; | 848 | this.globalData.no_clear=1; |
| @@ -892,7 +892,7 @@ App({ | @@ -892,7 +892,7 @@ App({ | ||
| 892 | }); | 892 | }); |
| 893 | }, | 893 | }, |
| 894 | 894 | ||
| 895 | - com_call(self) { | 895 | + com_call(self) { |
| 896 | self.getTel() | 896 | self.getTel() |
| 897 | .then(() => { | 897 | .then(() => { |
| 898 | if(self.data.store_tel) { | 898 | if(self.data.store_tel) { |
| @@ -912,6 +912,14 @@ App({ | @@ -912,6 +912,14 @@ App({ | ||
| 912 | }; | 912 | }; |
| 913 | }); | 913 | }); |
| 914 | }, | 914 | }, |
| 915 | + | ||
| 916 | + //检验能不能分享 | ||
| 917 | + check_can_share(){ | ||
| 918 | + if(!this.globalData.user_id) wx.hideShareMenu(); | ||
| 919 | + else wx.showShareMenu(); | ||
| 920 | + } | ||
| 921 | + | ||
| 922 | + | ||
| 915 | 923 | ||
| 916 | 924 | ||
| 917 | 925 |
packageA/pages/activity_share/activity_share.js
packageA/pages/addCustomer/addCustomer.js
packageA/pages/cardDetails/cardDetails.js
| @@ -39,6 +39,7 @@ Page({ | @@ -39,6 +39,7 @@ Page({ | ||
| 39 | * 生命周期函数--监听页面显示 | 39 | * 生命周期函数--监听页面显示 |
| 40 | */ | 40 | */ |
| 41 | onShow: function () { | 41 | onShow: function () { |
| 42 | + getApp().check_can_share(); | ||
| 42 | if(app.globalData.userInfo) { | 43 | if(app.globalData.userInfo) { |
| 43 | if(!this.data.isLogin) { | 44 | if(!this.data.isLogin) { |
| 44 | this.setData({ | 45 | this.setData({ |
packageA/pages/cardList/cardList.js
| @@ -52,6 +52,7 @@ Page({ | @@ -52,6 +52,7 @@ Page({ | ||
| 52 | * 生命周期函数--监听页面显示 | 52 | * 生命周期函数--监听页面显示 |
| 53 | */ | 53 | */ |
| 54 | onShow: function () { | 54 | onShow: function () { |
| 55 | + getApp().check_can_share(); | ||
| 55 | let url = '/api/weshop/serviceCard/page'; | 56 | let url = '/api/weshop/serviceCard/page'; |
| 56 | let currentQuery = this.data.currentQuery; | 57 | let currentQuery = this.data.currentQuery; |
| 57 | if(app.globalData.userInfo) { | 58 | if(app.globalData.userInfo) { |
packageA/pages/chongzhi/chongzhi.js
packageA/pages/chongzhiDetails/chongzhiDetails.js
packageA/pages/choujiang/choujiang.js
packageA/pages/details_serviceCard/details_serviceCard.js
| @@ -42,6 +42,7 @@ Page({ | @@ -42,6 +42,7 @@ Page({ | ||
| 42 | * 生命周期函数--监听页面显示 | 42 | * 生命周期函数--监听页面显示 |
| 43 | */ | 43 | */ |
| 44 | onShow: function() { | 44 | onShow: function() { |
| 45 | + getApp().check_can_share(); | ||
| 45 | if (app.globalData.userInfo) { | 46 | if (app.globalData.userInfo) { |
| 46 | if (!this.data.isLogin) { | 47 | if (!this.data.isLogin) { |
| 47 | this.setData({ | 48 | this.setData({ |
packageA/pages/distribution/card/card.js
| @@ -38,6 +38,7 @@ Page({ | @@ -38,6 +38,7 @@ Page({ | ||
| 38 | * 生命周期函数--监听页面显示 | 38 | * 生命周期函数--监听页面显示 |
| 39 | */ | 39 | */ |
| 40 | onShow: function () { | 40 | onShow: function () { |
| 41 | + getApp().check_can_share(); | ||
| 41 | if(app.globalData.userInfo) { | 42 | if(app.globalData.userInfo) { |
| 42 | if(!this.data.isLogin) { | 43 | if(!this.data.isLogin) { |
| 43 | this.setData({ | 44 | this.setData({ |
packageA/pages/distribution/commision/commision.js
| @@ -74,6 +74,7 @@ Page({ | @@ -74,6 +74,7 @@ Page({ | ||
| 74 | * 生命周期函数--监听页面显示 | 74 | * 生命周期函数--监听页面显示 |
| 75 | */ | 75 | */ |
| 76 | onShow: function () { | 76 | onShow: function () { |
| 77 | + getApp().check_can_share(); | ||
| 77 | 78 | ||
| 78 | if(app.globalData.userInfo) { | 79 | if(app.globalData.userInfo) { |
| 79 | if(!this.data.isLogin) { | 80 | if(!this.data.isLogin) { |
packageA/pages/distribution/goods/goods.js
| @@ -97,6 +97,8 @@ Page({ | @@ -97,6 +97,8 @@ Page({ | ||
| 97 | * 生命周期函数--监听页面显示 | 97 | * 生命周期函数--监听页面显示 |
| 98 | */ | 98 | */ |
| 99 | onShow: function () { | 99 | onShow: function () { |
| 100 | + | ||
| 101 | + getApp().check_can_share(); | ||
| 100 | let url = '/api/weshop/goods/page'; | 102 | let url = '/api/weshop/goods/page'; |
| 101 | let currentQuery = this.data.currentQuery; | 103 | let currentQuery = this.data.currentQuery; |
| 102 | if(app.globalData.userInfo) { | 104 | if(app.globalData.userInfo) { |
packageA/pages/distribution/myteam/myteam.js
| @@ -69,6 +69,7 @@ Page({ | @@ -69,6 +69,7 @@ Page({ | ||
| 69 | * 生命周期函数--监听页面显示 | 69 | * 生命周期函数--监听页面显示 |
| 70 | */ | 70 | */ |
| 71 | onShow: function () { | 71 | onShow: function () { |
| 72 | + getApp().check_can_share(); | ||
| 72 | if(app.globalData.userInfo) { | 73 | if(app.globalData.userInfo) { |
| 73 | if(!this.data.isLogin) { | 74 | if(!this.data.isLogin) { |
| 74 | this.setData({ | 75 | this.setData({ |
packageA/pages/distribution/order/order.js
| @@ -78,6 +78,7 @@ Page({ | @@ -78,6 +78,7 @@ Page({ | ||
| 78 | * 生命周期函数--监听页面显示 | 78 | * 生命周期函数--监听页面显示 |
| 79 | */ | 79 | */ |
| 80 | onShow: function () { | 80 | onShow: function () { |
| 81 | + getApp().check_can_share(); | ||
| 81 | if(app.globalData.userInfo) { | 82 | if(app.globalData.userInfo) { |
| 82 | if(!this.data.isLogin) { | 83 | if(!this.data.isLogin) { |
| 83 | this.setData({ | 84 | this.setData({ |
packageA/pages/distribution/rank/rank.js
| @@ -67,6 +67,7 @@ Page({ | @@ -67,6 +67,7 @@ Page({ | ||
| 67 | * 生命周期函数--监听页面显示 | 67 | * 生命周期函数--监听页面显示 |
| 68 | */ | 68 | */ |
| 69 | onShow: function () { | 69 | onShow: function () { |
| 70 | + getApp().check_can_share(); | ||
| 70 | if(app.globalData.userInfo) { | 71 | if(app.globalData.userInfo) { |
| 71 | if(!this.data.isLogin) { | 72 | if(!this.data.isLogin) { |
| 72 | this.setData({ | 73 | this.setData({ |
packageA/pages/distribution/rookie/rookie.js
| @@ -58,6 +58,7 @@ Page({ | @@ -58,6 +58,7 @@ Page({ | ||
| 58 | * 生命周期函数--监听页面显示 | 58 | * 生命周期函数--监听页面显示 |
| 59 | */ | 59 | */ |
| 60 | onShow: function () { | 60 | onShow: function () { |
| 61 | + getApp().check_can_share(); | ||
| 61 | if(app.globalData.userInfo instanceof Object) { | 62 | if(app.globalData.userInfo instanceof Object) { |
| 62 | this.setData({ | 63 | this.setData({ |
| 63 | userInfo: app.globalData.userInfo, | 64 | userInfo: app.globalData.userInfo, |
packageA/pages/distribution/shop/shop.js
| @@ -95,6 +95,8 @@ Page({ | @@ -95,6 +95,8 @@ Page({ | ||
| 95 | * 生命周期函数--监听页面显示 | 95 | * 生命周期函数--监听页面显示 |
| 96 | */ | 96 | */ |
| 97 | onShow: function () { | 97 | onShow: function () { |
| 98 | + getApp().check_can_share(); | ||
| 99 | + | ||
| 98 | //自己登录的 | 100 | //自己登录的 |
| 99 | if (app.globalData.userInfo && !this.data.first_leader) { | 101 | if (app.globalData.userInfo && !this.data.first_leader) { |
| 100 | if (!this.data.isLogin) { | 102 | if (!this.data.isLogin) { |
packageA/pages/goodsInfo/goodsInfo.js
| @@ -668,6 +668,9 @@ Page({ | @@ -668,6 +668,9 @@ Page({ | ||
| 668 | //---展示--- | 668 | //---展示--- |
| 669 | // gid 在onload阶段已经保存在this.data中 | 669 | // gid 在onload阶段已经保存在this.data中 |
| 670 | onShow: function() { | 670 | onShow: function() { |
| 671 | + | ||
| 672 | + getApp().check_can_share(); | ||
| 673 | + | ||
| 671 | var that=this; | 674 | var that=this; |
| 672 | var ee = this,gid = this.data.gid, i = getApp().request; | 675 | var ee = this,gid = this.data.gid, i = getApp().request; |
| 673 | this.data.is_timer = 1; | 676 | this.data.is_timer = 1; |
packageA/pages/goods_share/goods_share.js
| @@ -123,9 +123,9 @@ Page({ | @@ -123,9 +123,9 @@ Page({ | ||
| 123 | 123 | ||
| 124 | /*** 生命周期函数--监听页面显示***/ | 124 | /*** 生命周期函数--监听页面显示***/ |
| 125 | onShow: function () { | 125 | onShow: function () { |
| 126 | + getApp().check_can_share(); | ||
| 126 | var th=this; | 127 | var th=this; |
| 127 | - | ||
| 128 | - | 128 | + |
| 129 | if(app.globalData.userInfo) { | 129 | if(app.globalData.userInfo) { |
| 130 | this.setData({ | 130 | this.setData({ |
| 131 | //用来判断是否是分销商,是分销商才显示分成佣金 | 131 | //用来判断是否是分销商,是分销商才显示分成佣金 |
packageA/pages/hongBao/hongBao.js
packageA/pages/hongBaoDetails/hongBaoDetails.js
packageA/pages/jfbuy/jfbuy.js
packageA/pages/liveStream/liveStream.js
| @@ -229,6 +229,8 @@ Page({ | @@ -229,6 +229,8 @@ Page({ | ||
| 229 | * 生命周期函数--监听页面显示 | 229 | * 生命周期函数--监听页面显示 |
| 230 | */ | 230 | */ |
| 231 | onShow: function () { | 231 | onShow: function () { |
| 232 | + | ||
| 233 | + getApp().check_can_share(); | ||
| 232 | if(app.globalData.userInfo) { | 234 | if(app.globalData.userInfo) { |
| 233 | if(!this.data.isLogin) { | 235 | if(!this.data.isLogin) { |
| 234 | this.setData({ | 236 | this.setData({ |
packageA/pages/liveStreamDetails/liveStreamDetails.js
| @@ -53,6 +53,11 @@ Page({ | @@ -53,6 +53,11 @@ Page({ | ||
| 53 | 53 | ||
| 54 | // 分享操作表 | 54 | // 分享操作表 |
| 55 | clickShare: function () { | 55 | clickShare: function () { |
| 56 | + | ||
| 57 | + if(!getApp().globalData.user_id){ | ||
| 58 | + getApp().goto("/pages/togoin/togoin"); | ||
| 59 | + return false; | ||
| 60 | + } | ||
| 56 | this.setData({ | 61 | this.setData({ |
| 57 | showActionSheet: !this.data.showActionSheet | 62 | showActionSheet: !this.data.showActionSheet |
| 58 | }) | 63 | }) |
| @@ -570,7 +575,7 @@ drawText: function(ctx, str, leftWidth, initHeight, titleHeight, canvasWidth, un | @@ -570,7 +575,7 @@ drawText: function(ctx, str, leftWidth, initHeight, titleHeight, canvasWidth, un | ||
| 570 | * 生命周期函数--监听页面显示 | 575 | * 生命周期函数--监听页面显示 |
| 571 | */ | 576 | */ |
| 572 | onShow: function () { | 577 | onShow: function () { |
| 573 | - | 578 | + getApp().check_can_share(); |
| 574 | }, | 579 | }, |
| 575 | 580 | ||
| 576 | /** | 581 | /** |
packageA/pages/live_share/live_share.js
packageA/pages/myGift/myGift.js
| @@ -67,6 +67,8 @@ Page({ | @@ -67,6 +67,8 @@ Page({ | ||
| 67 | * 生命周期函数--监听页面显示 | 67 | * 生命周期函数--监听页面显示 |
| 68 | */ | 68 | */ |
| 69 | onShow: function () { | 69 | onShow: function () { |
| 70 | + | ||
| 71 | + getApp().check_can_share(); | ||
| 70 | if(app.globalData.userInfo) { | 72 | if(app.globalData.userInfo) { |
| 71 | if(!this.data.isLogin) { | 73 | if(!this.data.isLogin) { |
| 72 | this.setData({ | 74 | this.setData({ |
packageA/pages/myGiftDetails/myGiftDetails.js
| @@ -57,6 +57,7 @@ Page({ | @@ -57,6 +57,7 @@ Page({ | ||
| 57 | * 生命周期函数--监听页面显示 | 57 | * 生命周期函数--监听页面显示 |
| 58 | */ | 58 | */ |
| 59 | onShow: function () { | 59 | onShow: function () { |
| 60 | + getApp().check_can_share(); | ||
| 60 | if(app.globalData.userInfo) { | 61 | if(app.globalData.userInfo) { |
| 61 | if(!this.data.isLogin) { | 62 | if(!this.data.isLogin) { |
| 62 | this.setData({ | 63 | this.setData({ |
packageA/pages/parseHtml/parseHtml.js
packageA/pages/profile/profile.js
| @@ -688,6 +688,9 @@ Page({ | @@ -688,6 +688,9 @@ Page({ | ||
| 688 | }, | 688 | }, |
| 689 | 689 | ||
| 690 | onShow: function() { | 690 | onShow: function() { |
| 691 | + | ||
| 692 | + getApp().check_can_share(); | ||
| 693 | + | ||
| 691 | var e = this; | 694 | var e = this; |
| 692 | if (this.data.is_zy) return false; | 695 | if (this.data.is_zy) return false; |
| 693 | this.wait_for_store_config(); | 696 | this.wait_for_store_config(); |
packageA/pages/prom_list/prom_list.js
| @@ -162,6 +162,9 @@ Page({ | @@ -162,6 +162,9 @@ Page({ | ||
| 162 | 162 | ||
| 163 | //---展示--- | 163 | //---展示--- |
| 164 | onShow: function() { | 164 | onShow: function() { |
| 165 | + | ||
| 166 | + getApp().check_can_share(); | ||
| 167 | + | ||
| 165 | var ee=this,th=ee,that=ee; | 168 | var ee=this,th=ee,that=ee; |
| 166 | var gid = this.data.gid,i = getApp().request; | 169 | var gid = this.data.gid,i = getApp().request; |
| 167 | ee.data.g_buy_num = new Map(); | 170 | ee.data.g_buy_num = new Map(); |
packageA/pages/quan/quan.js
packageA/pages/service_share/service_share.js
| @@ -97,6 +97,8 @@ Page({ | @@ -97,6 +97,8 @@ Page({ | ||
| 97 | 97 | ||
| 98 | /*** 生命周期函数--监听页面显示***/ | 98 | /*** 生命周期函数--监听页面显示***/ |
| 99 | onShow: function () { | 99 | onShow: function () { |
| 100 | + getApp().check_can_share(); | ||
| 101 | + | ||
| 100 | var th=this; | 102 | var th=this; |
| 101 | getApp().getConfig2(function(rs){ | 103 | getApp().getConfig2(function(rs){ |
| 102 | //计算等级价相关 | 104 | //计算等级价相关 |
packageA/pages/user/my_service2/appment_main.js
packageB/pages/boxes-details/boxes-details.js
| @@ -51,6 +51,8 @@ Page({ | @@ -51,6 +51,8 @@ Page({ | ||
| 51 | * 生命周期函数--监听页面显示 | 51 | * 生命周期函数--监听页面显示 |
| 52 | */ | 52 | */ |
| 53 | onShow: function() { | 53 | onShow: function() { |
| 54 | + getApp().check_can_share(); | ||
| 55 | + | ||
| 54 | // console.log('show~~~'); | 56 | // console.log('show~~~'); |
| 55 | if (app.globalData.userInfo) { | 57 | if (app.globalData.userInfo) { |
| 56 | if (!this.data.isLogin) { | 58 | if (!this.data.isLogin) { |
packageB/pages/luckactivity/index/index.js
| @@ -69,6 +69,8 @@ Page({ | @@ -69,6 +69,8 @@ Page({ | ||
| 69 | * 生命周期函数--监听页面显示 | 69 | * 生命周期函数--监听页面显示 |
| 70 | */ | 70 | */ |
| 71 | onShow: function () { | 71 | onShow: function () { |
| 72 | + getApp().check_can_share(); | ||
| 73 | + | ||
| 72 | if(app.globalData.userInfo) { | 74 | if(app.globalData.userInfo) { |
| 73 | if(!this.data.isLogin) { | 75 | if(!this.data.isLogin) { |
| 74 | this.setData({ | 76 | this.setData({ |
packageB/pages/user/Change_phone/Change_phone.js
packageB/pages/user/binding_info/binding_info.js
packageB/pages/user/buyDetails/buyDetails.js
| @@ -40,6 +40,7 @@ Page({ | @@ -40,6 +40,7 @@ Page({ | ||
| 40 | * 生命周期函数--监听页面显示 | 40 | * 生命周期函数--监听页面显示 |
| 41 | */ | 41 | */ |
| 42 | onShow: function () { | 42 | onShow: function () { |
| 43 | + getApp().check_can_share(); | ||
| 43 | if(app.globalData.userInfo) { | 44 | if(app.globalData.userInfo) { |
| 44 | if(!this.data.isLogin) { | 45 | if(!this.data.isLogin) { |
| 45 | this.setData({ | 46 | this.setData({ |
packageB/pages/user/choice_guide/choice_guide.js
| @@ -19,6 +19,7 @@ Page({ | @@ -19,6 +19,7 @@ Page({ | ||
| 19 | onLoad: function(t) {}, | 19 | onLoad: function(t) {}, |
| 20 | 20 | ||
| 21 | onShow: function() { | 21 | onShow: function() { |
| 22 | + getApp().check_can_share(); | ||
| 22 | this.data.ismore=0;this.data.isload=0; | 23 | this.data.ismore=0;this.data.isload=0; |
| 23 | this.setData({list:null}); | 24 | this.setData({list:null}); |
| 24 | this.get_list(); | 25 | this.get_list(); |
packageB/pages/video/index.js
| @@ -26,6 +26,8 @@ Page({ | @@ -26,6 +26,8 @@ Page({ | ||
| 26 | }) | 26 | }) |
| 27 | }, | 27 | }, |
| 28 | onShow:function(){ | 28 | onShow:function(){ |
| 29 | + getApp().check_can_share(); | ||
| 30 | + | ||
| 29 | var goods_list = this.selectComponent("#goods_list"); //组件的id | 31 | var goods_list = this.selectComponent("#goods_list"); //组件的id |
| 30 | goods_list.init(); | 32 | goods_list.init(); |
| 31 | setTimeout(function() { | 33 | setTimeout(function() { |
packageB/pages/zuhegou/index/index.js
| @@ -160,6 +160,8 @@ Page({ | @@ -160,6 +160,8 @@ Page({ | ||
| 160 | * 生命周期函数--监听页面显示 | 160 | * 生命周期函数--监听页面显示 |
| 161 | */ | 161 | */ |
| 162 | onShow: function () { | 162 | onShow: function () { |
| 163 | + getApp().check_can_share(); | ||
| 164 | + | ||
| 163 | getApp().is_Single_page(this, function () { | 165 | getApp().is_Single_page(this, function () { |
| 164 | var th = this, | 166 | var th = this, |
| 165 | that = this, | 167 | that = this, |
packageB/pages/zuhegou/list/list.js
| @@ -65,7 +65,10 @@ Page({ | @@ -65,7 +65,10 @@ Page({ | ||
| 65 | }, | 65 | }, |
| 66 | 66 | ||
| 67 | 67 | ||
| 68 | - onShow: function(t) { | 68 | + onShow: function(t) { |
| 69 | + | ||
| 70 | + getApp().check_can_share(); | ||
| 71 | + | ||
| 69 | this.data.ismore=1; | 72 | this.data.ismore=1; |
| 70 | this.data.is_timer=1; | 73 | this.data.is_timer=1; |
| 71 | this.data.currentPage=1; | 74 | this.data.currentPage=1; |
packageB/pages/zuhegou/preindex/index.js
| @@ -159,6 +159,8 @@ Page({ | @@ -159,6 +159,8 @@ Page({ | ||
| 159 | * 生命周期函数--监听页面显示 | 159 | * 生命周期函数--监听页面显示 |
| 160 | */ | 160 | */ |
| 161 | onShow: function () { | 161 | onShow: function () { |
| 162 | + getApp().check_can_share(); | ||
| 163 | + | ||
| 162 | getApp().is_Single_page(this, function () { | 164 | getApp().is_Single_page(this, function () { |
| 163 | var th = this, | 165 | var th = this, |
| 164 | that = this, | 166 | that = this, |
packageC/pages/goods/distributionCategoryList/index.js
| @@ -231,6 +231,8 @@ Page({ | @@ -231,6 +231,8 @@ Page({ | ||
| 231 | }) | 231 | }) |
| 232 | }, | 232 | }, |
| 233 | onShow: function () { | 233 | onShow: function () { |
| 234 | + | ||
| 235 | + getApp().check_can_share(); | ||
| 234 | if (t.globalData.userInfo) { | 236 | if (t.globalData.userInfo) { |
| 235 | let currentData = { | 237 | let currentData = { |
| 236 | store_id: t.globalData.setting.stoid, | 238 | store_id: t.globalData.setting.stoid, |
packageC/pages/goods/goodsList/goodsList.js
| @@ -119,6 +119,11 @@ Page({ | @@ -119,6 +119,11 @@ Page({ | ||
| 119 | } | 119 | } |
| 120 | }); | 120 | }); |
| 121 | }, | 121 | }, |
| 122 | + | ||
| 123 | + onShow:function () { | ||
| 124 | + getApp().check_can_share(); | ||
| 125 | + }, | ||
| 126 | + | ||
| 122 | //设置优惠券的 | 127 | //设置优惠券的 |
| 123 | set_prom_list: async function (arr) { | 128 | set_prom_list: async function (arr) { |
| 124 | var th = this; | 129 | var th = this; |
| @@ -313,4 +318,6 @@ Page({ | @@ -313,4 +318,6 @@ Page({ | ||
| 313 | }, | 318 | }, |
| 314 | 319 | ||
| 315 | 320 | ||
| 321 | + | ||
| 322 | + | ||
| 316 | }); | 323 | }); |
| 317 | \ No newline at end of file | 324 | \ No newline at end of file |
packageC/pages/goods/search/search.js
packageC/pages/group_list/group_list.js
| @@ -44,6 +44,7 @@ Page({ | @@ -44,6 +44,7 @@ Page({ | ||
| 44 | * 生命周期函数--监听页面显示 | 44 | * 生命周期函数--监听页面显示 |
| 45 | */ | 45 | */ |
| 46 | onShow: function () { | 46 | onShow: function () { |
| 47 | + getApp().check_can_share(); | ||
| 47 | if(app.globalData.userInfo) { | 48 | if(app.globalData.userInfo) { |
| 48 | if(!this.data.isLogin) { | 49 | if(!this.data.isLogin) { |
| 49 | this.setData({ | 50 | this.setData({ |
packageC/pages/luckyGo/luckyGo_activityList/luckyGo_activityList.js
| @@ -35,6 +35,7 @@ Page({ | @@ -35,6 +35,7 @@ Page({ | ||
| 35 | }, | 35 | }, |
| 36 | 36 | ||
| 37 | onShow: function() { | 37 | onShow: function() { |
| 38 | + getApp().check_can_share(); | ||
| 38 | if(app.globalData.userInfo) { | 39 | if(app.globalData.userInfo) { |
| 39 | if(!this.data.isLogin) { | 40 | if(!this.data.isLogin) { |
| 40 | this.setData({ | 41 | this.setData({ |
packageC/pages/luckyGo/luckyGo_details/luckyGo_details.js
| @@ -106,6 +106,7 @@ Page({ | @@ -106,6 +106,7 @@ Page({ | ||
| 106 | }, | 106 | }, |
| 107 | 107 | ||
| 108 | onShow: function() { | 108 | onShow: function() { |
| 109 | + getApp().check_can_share(); | ||
| 109 | this.get_team_info(); | 110 | this.get_team_info(); |
| 110 | }, | 111 | }, |
| 111 | 112 | ||
| @@ -1009,6 +1010,10 @@ Page({ | @@ -1009,6 +1010,10 @@ Page({ | ||
| 1009 | // }, | 1010 | // }, |
| 1010 | 1011 | ||
| 1011 | clickShare() { | 1012 | clickShare() { |
| 1013 | + if(!getApp().globalData.user_id){ | ||
| 1014 | + getApp().goto("/pages/togoin/togoin"); | ||
| 1015 | + return false; | ||
| 1016 | + } | ||
| 1012 | this.setData({ | 1017 | this.setData({ |
| 1013 | share_hidden: true, | 1018 | share_hidden: true, |
| 1014 | }); | 1019 | }); |
packageC/pages/luckyGo/luckyGo_goodsInfo/luckyGo_goodsInfo.js
| @@ -756,6 +756,8 @@ Page({ | @@ -756,6 +756,8 @@ Page({ | ||
| 756 | 756 | ||
| 757 | //---展示--- | 757 | //---展示--- |
| 758 | onShow: async function () { | 758 | onShow: async function () { |
| 759 | + | ||
| 760 | + getApp().check_can_share(); | ||
| 759 | // console.log('onshow'); | 761 | // console.log('onshow'); |
| 760 | var goods_list = null, th = this, that = this; | 762 | var goods_list = null, th = this, that = this; |
| 761 | var show_prew_img = this.data.show_prew_img | 763 | var show_prew_img = this.data.show_prew_img |
| @@ -6196,6 +6198,10 @@ Page({ | @@ -6196,6 +6198,10 @@ Page({ | ||
| 6196 | }, | 6198 | }, |
| 6197 | 6199 | ||
| 6198 | clickShare() { | 6200 | clickShare() { |
| 6201 | + if(!getApp().globalData.user_id){ | ||
| 6202 | + getApp().goto("/pages/togoin/togoin"); | ||
| 6203 | + return false; | ||
| 6204 | + } | ||
| 6199 | this.setData({ | 6205 | this.setData({ |
| 6200 | share_hidden: true, | 6206 | share_hidden: true, |
| 6201 | }); | 6207 | }); |
packageC/pages/luckyGo/luckyGo_members/luckyGo_members.js
| @@ -34,6 +34,7 @@ Page({ | @@ -34,6 +34,7 @@ Page({ | ||
| 34 | * 生命周期函数--监听页面显示 | 34 | * 生命周期函数--监听页面显示 |
| 35 | */ | 35 | */ |
| 36 | onShow: function () { | 36 | onShow: function () { |
| 37 | + getApp().check_can_share(); | ||
| 37 | if(app.globalData.userInfo) { | 38 | if(app.globalData.userInfo) { |
| 38 | if(!this.data.isLogin) { | 39 | if(!this.data.isLogin) { |
| 39 | this.setData({ | 40 | this.setData({ |
packageC/pages/luckyGo/luckyGo_winners/luckyGo_winners.js
| @@ -38,6 +38,7 @@ Page({ | @@ -38,6 +38,7 @@ Page({ | ||
| 38 | * 生命周期函数--监听页面显示 | 38 | * 生命周期函数--监听页面显示 |
| 39 | */ | 39 | */ |
| 40 | onShow: function () { | 40 | onShow: function () { |
| 41 | + getApp().check_can_share(); | ||
| 41 | if(app.globalData.userInfo) { | 42 | if(app.globalData.userInfo) { |
| 42 | if(!this.data.isLogin) { | 43 | if(!this.data.isLogin) { |
| 43 | this.setData({ | 44 | this.setData({ |
packageC/pages/presell/goodsInfo/goodsInfo.js
| @@ -593,6 +593,7 @@ Page({ | @@ -593,6 +593,7 @@ Page({ | ||
| 593 | 593 | ||
| 594 | //---展示--- | 594 | //---展示--- |
| 595 | onShow: function () { | 595 | onShow: function () { |
| 596 | + getApp().check_can_share(); | ||
| 596 | var goods_list = null, th = this, that = this; | 597 | var goods_list = null, th = this, that = this; |
| 597 | 598 | ||
| 598 | //-- 如果是预览图片,页面不重新更新 -- | 599 | //-- 如果是预览图片,页面不重新更新 -- |
| @@ -3844,6 +3845,10 @@ Page({ | @@ -3844,6 +3845,10 @@ Page({ | ||
| 3844 | }, | 3845 | }, |
| 3845 | 3846 | ||
| 3846 | clickShare() { | 3847 | clickShare() { |
| 3848 | + if(!getApp().globalData.user_id){ | ||
| 3849 | + getApp().goto("/pages/togoin/togoin"); | ||
| 3850 | + return false; | ||
| 3851 | + } | ||
| 3847 | this.setData({ share_hidden: true, }); | 3852 | this.setData({ share_hidden: true, }); |
| 3848 | }, | 3853 | }, |
| 3849 | 3854 |
packageC/pages/presell/pregoodsInfo/goodsInfo.js
| @@ -590,6 +590,8 @@ Page({ | @@ -590,6 +590,8 @@ Page({ | ||
| 590 | 590 | ||
| 591 | //---展示--- | 591 | //---展示--- |
| 592 | onShow: function () { | 592 | onShow: function () { |
| 593 | + | ||
| 594 | + getApp().check_can_share(); | ||
| 593 | var goods_list = null, th = this, that = this; | 595 | var goods_list = null, th = this, that = this; |
| 594 | 596 | ||
| 595 | //-- 如果是预览图片,页面不重新更新 -- | 597 | //-- 如果是预览图片,页面不重新更新 -- |
| @@ -3807,7 +3809,11 @@ Page({ | @@ -3807,7 +3809,11 @@ Page({ | ||
| 3807 | }, | 3809 | }, |
| 3808 | 3810 | ||
| 3809 | clickShare() { | 3811 | clickShare() { |
| 3810 | - this.setData({ share_hidden: true, }); | 3812 | + if(!getApp().globalData.user_id){ |
| 3813 | + getApp().goto("/pages/togoin/togoin"); | ||
| 3814 | + return false; | ||
| 3815 | + } | ||
| 3816 | + this.setData({ share_hidden: true, }); | ||
| 3811 | }, | 3817 | }, |
| 3812 | 3818 | ||
| 3813 | send() { | 3819 | send() { |
packageD/pages/AI-test-skin/history_record/history_record.js
| @@ -304,7 +304,7 @@ Page({ | @@ -304,7 +304,7 @@ Page({ | ||
| 304 | * 生命周期函数--监听页面显示 | 304 | * 生命周期函数--监听页面显示 |
| 305 | */ | 305 | */ |
| 306 | onShow: function () { | 306 | onShow: function () { |
| 307 | - | 307 | + getApp().check_can_share(); |
| 308 | }, | 308 | }, |
| 309 | go_result(e) { | 309 | go_result(e) { |
| 310 | let id = e.currentTarget.dataset.id; | 310 | let id = e.currentTarget.dataset.id; |
packageD/pages/AI-test-skin/index/aiskin.js
packageD/pages/AI-test-skin/shoot_notice/shoot_notice.js
packageD/pages/AI-test-skin/success_result/success_result.js
| @@ -480,7 +480,9 @@ Page({ | @@ -480,7 +480,9 @@ Page({ | ||
| 480 | /** | 480 | /** |
| 481 | * 生命周期函数--监听页面显示 | 481 | * 生命周期函数--监听页面显示 |
| 482 | */ | 482 | */ |
| 483 | - onShow: function () { }, | 483 | + onShow: function () { |
| 484 | + getApp().check_can_share(); | ||
| 485 | + }, | ||
| 484 | 486 | ||
| 485 | clickTab(e) { | 487 | clickTab(e) { |
| 486 | let { index, tab_id } = e.currentTarget.dataset; | 488 | let { index, tab_id } = e.currentTarget.dataset; |
pages/activity/pind_list/pind_list.js
| @@ -65,6 +65,7 @@ Page({ | @@ -65,6 +65,7 @@ Page({ | ||
| 65 | }, | 65 | }, |
| 66 | 66 | ||
| 67 | onShow: function (t) { | 67 | onShow: function (t) { |
| 68 | + getApp().check_can_share(); | ||
| 68 | this.data.is_timer = 1; | 69 | this.data.is_timer = 1; |
| 69 | this.data.currentPage = 1; | 70 | this.data.currentPage = 1; |
| 70 | this.data.ismore = 1; | 71 | this.data.ismore = 1; |
pages/activity/seckill_list/seckill_list.js
pages/cart/cart_wk/cart_wk.js
| @@ -70,6 +70,7 @@ Page({ | @@ -70,6 +70,7 @@ Page({ | ||
| 70 | * 生命周期函数--监听页面显示 | 70 | * 生命周期函数--监听页面显示 |
| 71 | */ | 71 | */ |
| 72 | onShow: function () { | 72 | onShow: function () { |
| 73 | + getApp().check_can_share(); | ||
| 73 | var th = this; | 74 | var th = this; |
| 74 | if (th.data.isclose == 0) { | 75 | if (th.data.isclose == 0) { |
| 75 | wx.navigateTo({ | 76 | wx.navigateTo({ |
pages/distribution/distribution.js
| @@ -57,7 +57,8 @@ Page({ | @@ -57,7 +57,8 @@ Page({ | ||
| 57 | /** | 57 | /** |
| 58 | * 生命周期函数--监听页面显示 | 58 | * 生命周期函数--监听页面显示 |
| 59 | */ | 59 | */ |
| 60 | - onShow: function () { | 60 | + onShow: function () { |
| 61 | + getApp().check_can_share(); | ||
| 61 | if (typeof this.getTabBar === 'function' && this.getTabBar()) { | 62 | if (typeof this.getTabBar === 'function' && this.getTabBar()) { |
| 62 | this.getTabBar().setData({ | 63 | this.getTabBar().setData({ |
| 63 | active: 2 | 64 | active: 2 |
pages/giftpack/buygiftpack/giftpackbuy.js
| @@ -79,6 +79,7 @@ Page({ | @@ -79,6 +79,7 @@ Page({ | ||
| 79 | this.getList(); | 79 | this.getList(); |
| 80 | }, | 80 | }, |
| 81 | onShow: function () { | 81 | onShow: function () { |
| 82 | + getApp().check_can_share(); | ||
| 82 | //--先判断会员状态-- | 83 | //--先判断会员状态-- |
| 83 | getApp().is_Single_page(this, function () { | 84 | getApp().is_Single_page(this, function () { |
| 84 | var user_info = getApp().globalData.userInfo; | 85 | var user_info = getApp().globalData.userInfo; |
pages/giftpack/giftpacklist/giftpacklist.js
| @@ -73,6 +73,7 @@ Page({ | @@ -73,6 +73,7 @@ Page({ | ||
| 73 | }, | 73 | }, |
| 74 | 74 | ||
| 75 | onShow: function () { | 75 | onShow: function () { |
| 76 | + getApp().check_can_share(); | ||
| 76 | getApp().is_Single_page(this,function () { | 77 | getApp().is_Single_page(this,function () { |
| 77 | //--先判断会员状态-- | 78 | //--先判断会员状态-- |
| 78 | var user_info = getApp().globalData.userInfo; | 79 | var user_info = getApp().globalData.userInfo; |
pages/giftpack/mygiftpack/mygiftpack.js
| @@ -78,6 +78,7 @@ Page({ | @@ -78,6 +78,7 @@ Page({ | ||
| 78 | this.getList(); | 78 | this.getList(); |
| 79 | }, | 79 | }, |
| 80 | onShow: function () { | 80 | onShow: function () { |
| 81 | + getApp().check_can_share(); | ||
| 81 | //--先判断会员状态-- | 82 | //--先判断会员状态-- |
| 82 | getApp().is_Single_page(this, function () { | 83 | getApp().is_Single_page(this, function () { |
| 83 | var user_info = getApp().globalData.userInfo; | 84 | var user_info = getApp().globalData.userInfo; |
pages/goods/categoryList/categoryList.js
| @@ -185,6 +185,7 @@ Page({ | @@ -185,6 +185,7 @@ Page({ | ||
| 185 | }); | 185 | }); |
| 186 | }, | 186 | }, |
| 187 | onShow:function(){ | 187 | onShow:function(){ |
| 188 | + getApp().check_can_share(); | ||
| 188 | 189 | ||
| 189 | if (typeof this.getTabBar === 'function' && this.getTabBar()) { | 190 | if (typeof this.getTabBar === 'function' && this.getTabBar()) { |
| 190 | var index=getApp().getPageIndex(this); | 191 | var index=getApp().getPageIndex(this); |
pages/goods/goodsInfo/goodsInfo.js
| @@ -763,7 +763,7 @@ Page({ | @@ -763,7 +763,7 @@ Page({ | ||
| 763 | //---展示--- | 763 | //---展示--- |
| 764 | onShow: function () { | 764 | onShow: function () { |
| 765 | 765 | ||
| 766 | - | 766 | + getApp().check_can_share(); |
| 767 | 767 | ||
| 768 | var goods_list = null, th = this, that = this; | 768 | var goods_list = null, th = this, that = this; |
| 769 | var show_prew_img = this.data.show_prew_img | 769 | var show_prew_img = this.data.show_prew_img |
| @@ -2404,7 +2404,8 @@ Page({ | @@ -2404,7 +2404,8 @@ Page({ | ||
| 2404 | }, | 2404 | }, |
| 2405 | 2405 | ||
| 2406 | //--点击分享事件--- | 2406 | //--点击分享事件--- |
| 2407 | - onShareAppMessage: function (t) { getApp().globalData.no_clear=1; | 2407 | + onShareAppMessage: function (t) { |
| 2408 | + getApp().globalData.no_clear=1; | ||
| 2408 | 2409 | ||
| 2409 | var th = this; | 2410 | var th = this; |
| 2410 | var price = th.data.sele_g.shop_price; | 2411 | var price = th.data.sele_g.shop_price; |
| @@ -6375,6 +6376,10 @@ Page({ | @@ -6375,6 +6376,10 @@ Page({ | ||
| 6375 | }, | 6376 | }, |
| 6376 | 6377 | ||
| 6377 | clickShare() { | 6378 | clickShare() { |
| 6379 | + if(!getApp().globalData.user_id){ | ||
| 6380 | + getApp().goto("/pages/togoin/togoin"); | ||
| 6381 | + return false; | ||
| 6382 | + } | ||
| 6378 | this.setData({ | 6383 | this.setData({ |
| 6379 | share_hidden: true, | 6384 | share_hidden: true, |
| 6380 | }); | 6385 | }); |
pages/goods/goodsList/goodsList.js
| @@ -200,6 +200,10 @@ Page({ | @@ -200,6 +200,10 @@ Page({ | ||
| 200 | }) | 200 | }) |
| 201 | }, | 201 | }, |
| 202 | 202 | ||
| 203 | + onShow:function () { | ||
| 204 | + getApp().check_can_share(); | ||
| 205 | + }, | ||
| 206 | + | ||
| 203 | //设置优惠券的 | 207 | //设置优惠券的 |
| 204 | set_prom_list:async function(arr){ | 208 | set_prom_list:async function(arr){ |
| 205 | var th=this; | 209 | var th=this; |
pages/goods/search/search.js
| @@ -139,8 +139,11 @@ Page({ | @@ -139,8 +139,11 @@ Page({ | ||
| 139 | // 获取历史搜索记录 | 139 | // 获取历史搜索记录 |
| 140 | this.getHistorySearch(); | 140 | this.getHistorySearch(); |
| 141 | }, | 141 | }, |
| 142 | - | ||
| 143 | - | 142 | + |
| 143 | + onShow:function () { | ||
| 144 | + getApp().check_can_share(); | ||
| 145 | + }, | ||
| 146 | + | ||
| 144 | changeTab: function(t) { | 147 | changeTab: function(t) { |
| 145 | var ord = t.currentTarget.dataset.href; | 148 | var ord = t.currentTarget.dataset.href; |
| 146 | var ad = t.currentTarget.dataset.ad; | 149 | var ad = t.currentTarget.dataset.ad; |
pages/index/index/index.js
| @@ -292,6 +292,9 @@ Page({ | @@ -292,6 +292,9 @@ Page({ | ||
| 292 | }, | 292 | }, |
| 293 | 293 | ||
| 294 | async onShow() { | 294 | async onShow() { |
| 295 | + | ||
| 296 | + getApp().check_can_share(); | ||
| 297 | + | ||
| 295 | this.getTabBar().setData({ | 298 | this.getTabBar().setData({ |
| 296 | cartGoodsNum: getApp().globalData.cartGoodsNum | 299 | cartGoodsNum: getApp().globalData.cartGoodsNum |
| 297 | }) | 300 | }) |
pages/team/team_show/team_show.js
| @@ -142,6 +142,7 @@ Page({ | @@ -142,6 +142,7 @@ Page({ | ||
| 142 | 142 | ||
| 143 | //显示加载 | 143 | //显示加载 |
| 144 | onShow:function(){ | 144 | onShow:function(){ |
| 145 | + getApp().check_can_share(); | ||
| 145 | var tg_id = this.data.tg_id,th=this; | 146 | var tg_id = this.data.tg_id,th=this; |
| 146 | this.init(tg_id); | 147 | this.init(tg_id); |
| 147 | }, | 148 | }, |
pages/team/team_success/team_success.js
| @@ -86,6 +86,10 @@ Page({ | @@ -86,6 +86,10 @@ Page({ | ||
| 86 | } | 86 | } |
| 87 | }) | 87 | }) |
| 88 | }, | 88 | }, |
| 89 | + onShow:function () { | ||
| 90 | + getApp().check_can_share(); | ||
| 91 | + }, | ||
| 92 | + | ||
| 89 | //关闭展开列表 | 93 | //关闭展开列表 |
| 90 | click:function(e){ | 94 | click:function(e){ |
| 91 | this.setData({ | 95 | this.setData({ |
| @@ -845,6 +849,10 @@ Page({ | @@ -845,6 +849,10 @@ Page({ | ||
| 845 | }, | 849 | }, |
| 846 | 850 | ||
| 847 | clickShare() { | 851 | clickShare() { |
| 852 | + if(!getApp().globalData.user_id){ | ||
| 853 | + getApp().goto("/pages/togoin/togoin"); | ||
| 854 | + return false; | ||
| 855 | + } | ||
| 848 | this.setData({ | 856 | this.setData({ |
| 849 | share_hidden: true, | 857 | share_hidden: true, |
| 850 | }); | 858 | }); |
pages/template/index.js
pages/user/assistance/assistance.js
| @@ -49,6 +49,7 @@ Page({ | @@ -49,6 +49,7 @@ Page({ | ||
| 49 | * 生命周期函数--监听页面显示 | 49 | * 生命周期函数--监听页面显示 |
| 50 | */ | 50 | */ |
| 51 | onShow: function () { | 51 | onShow: function () { |
| 52 | + getApp().check_can_share(); | ||
| 52 | //--先判断会员状态-- | 53 | //--先判断会员状态-- |
| 53 | getApp().is_Single_page(this, function () { | 54 | getApp().is_Single_page(this, function () { |
| 54 | var user_info = getApp().globalData.userInfo; | 55 | var user_info = getApp().globalData.userInfo; |
pages/user/assistance/friend_assistance.js
| @@ -54,6 +54,7 @@ Page({ | @@ -54,6 +54,7 @@ Page({ | ||
| 54 | * 生命周期函数--监听页面显示 | 54 | * 生命周期函数--监听页面显示 |
| 55 | */ | 55 | */ |
| 56 | onShow: function() { | 56 | onShow: function() { |
| 57 | + getApp().check_can_share(); | ||
| 57 | //--先判断会员状态-- | 58 | //--先判断会员状态-- |
| 58 | var user_info = getApp().globalData.userInfo; | 59 | var user_info = getApp().globalData.userInfo; |
| 59 | if (user_info == null || user_info.mobile == undefined || user_info.mobile == "" || user_info.mobile == null) { | 60 | if (user_info == null || user_info.mobile == undefined || user_info.mobile == "" || user_info.mobile == null) { |
pages/user/assistance/task_assistance.js
| @@ -147,7 +147,7 @@ Page({ | @@ -147,7 +147,7 @@ Page({ | ||
| 147 | * 生命周期函数--监听页面显示 | 147 | * 生命周期函数--监听页面显示 |
| 148 | */ | 148 | */ |
| 149 | onShow: function () { | 149 | onShow: function () { |
| 150 | - | 150 | + getApp().check_can_share(); |
| 151 | //--先判断会员状态-- | 151 | //--先判断会员状态-- |
| 152 | var user_info = getApp().globalData.userInfo; | 152 | var user_info = getApp().globalData.userInfo; |
| 153 | if (user_info == null || user_info.mobile == undefined || user_info.mobile == "" || user_info.mobile == null) { | 153 | if (user_info == null || user_info.mobile == undefined || user_info.mobile == "" || user_info.mobile == null) { |
pages/user/deposit/prepaid/msg/msg.js
pages/user/index/index.js
| @@ -84,6 +84,7 @@ Page({ | @@ -84,6 +84,7 @@ Page({ | ||
| 84 | * 生命周期函数--监听页面显示 | 84 | * 生命周期函数--监听页面显示 |
| 85 | */ | 85 | */ |
| 86 | onShow: function() { | 86 | onShow: function() { |
| 87 | + getApp().check_can_share(); | ||
| 87 | //看一下小程序是不是过期了 | 88 | //看一下小程序是不是过期了 |
| 88 | getApp().getConfig2(function(config2){ | 89 | getApp().getConfig2(function(config2){ |
| 89 | if(config2 && config2.is_overdue==1){ | 90 | if(config2 && config2.is_overdue==1){ |
pages/user/integral/integral.js
| @@ -307,6 +307,7 @@ Page({ | @@ -307,6 +307,7 @@ Page({ | ||
| 307 | * 生命周期函数--监听页面显示 | 307 | * 生命周期函数--监听页面显示 |
| 308 | */ | 308 | */ |
| 309 | onShow: function () { | 309 | onShow: function () { |
| 310 | + getApp().check_can_share(); | ||
| 310 | //--先判断会员状态-- | 311 | //--先判断会员状态-- |
| 311 | var user_info = getApp().globalData.userInfo; | 312 | var user_info = getApp().globalData.userInfo; |
| 312 | if (user_info == null || user_info.mobile == undefined || user_info.mobile == "" || user_info.mobile == null) { | 313 | if (user_info == null || user_info.mobile == undefined || user_info.mobile == "" || user_info.mobile == null) { |
pages/user/integral/msg/msg.js
pages/user/member/bring/bring.js
| @@ -328,6 +328,7 @@ Page({ | @@ -328,6 +328,7 @@ Page({ | ||
| 328 | * 生命周期函数--监听页面显示 | 328 | * 生命周期函数--监听页面显示 |
| 329 | */ | 329 | */ |
| 330 | onShow: function() { | 330 | onShow: function() { |
| 331 | + getApp().check_can_share(); | ||
| 331 | var th=this; | 332 | var th=this; |
| 332 | this.weixin(); | 333 | this.weixin(); |
| 333 | this.setData({ | 334 | this.setData({ |
pages/user/member/bring/msg/msg.js
pages/user/member/menber.js
| @@ -20,6 +20,7 @@ Page({ | @@ -20,6 +20,7 @@ Page({ | ||
| 20 | * 生命周期函数--监听页面显示 | 20 | * 生命周期函数--监听页面显示 |
| 21 | */ | 21 | */ |
| 22 | onShow: function () { | 22 | onShow: function () { |
| 23 | + getApp().check_can_share(); | ||
| 23 | var th=this; | 24 | var th=this; |
| 24 | //--先判断会员状态-- | 25 | //--先判断会员状态-- |
| 25 | var user_info = getApp().globalData.userInfo; | 26 | var user_info = getApp().globalData.userInfo; |
pages/user/user_spsy/user_spsy.js
| @@ -41,8 +41,7 @@ Page({ | @@ -41,8 +41,7 @@ Page({ | ||
| 41 | * 生命周期函数--监听页面显示 | 41 | * 生命周期函数--监听页面显示 |
| 42 | */ | 42 | */ |
| 43 | onShow: function () { | 43 | onShow: function () { |
| 44 | - | ||
| 45 | - | 44 | + getApp().check_can_share(); |
| 46 | }, | 45 | }, |
| 47 | async getQrCode(FormId,GradeId) { | 46 | async getQrCode(FormId,GradeId) { |
| 48 | const res = await getApp().request.promiseGet("/api/weshop/users/grade/wares/code/get", { | 47 | const res = await getApp().request.promiseGet("/api/weshop/users/grade/wares/code/get", { |
pages/user/userinfo/userinfo.js
| @@ -740,6 +740,7 @@ Page({ | @@ -740,6 +740,7 @@ Page({ | ||
| 740 | }, | 740 | }, |
| 741 | 741 | ||
| 742 | onShow: function() { | 742 | onShow: function() { |
| 743 | + getApp().check_can_share(); | ||
| 743 | var e = this; | 744 | var e = this; |
| 744 | if (this.data.is_zy) return false; | 745 | if (this.data.is_zy) return false; |
| 745 | this.wait_for_store_config(); | 746 | this.wait_for_store_config(); |
pages/user/userqy/userqy.js
| @@ -53,6 +53,7 @@ Page({ | @@ -53,6 +53,7 @@ Page({ | ||
| 53 | * 生命周期函数--监听页面显示 | 53 | * 生命周期函数--监听页面显示 |
| 54 | */ | 54 | */ |
| 55 | onShow: async function () { | 55 | onShow: async function () { |
| 56 | + getApp().check_can_share(); | ||
| 56 | wx.showLoading(); | 57 | wx.showLoading(); |
| 57 | var cz_val=0,backClass=null,qy_list=null,gradeId=null,gradeEndDate=null,need_money=0,g_qy_list=null,GradeName='',cur_g_num=0; | 58 | var cz_val=0,backClass=null,qy_list=null,gradeId=null,gradeEndDate=null,need_money=0,g_qy_list=null,GradeName='',cur_g_num=0; |
| 58 | var gl_data=getApp().globalData; | 59 | var gl_data=getApp().globalData; |