diff --git a/components/goodClass/index.vue b/components/goodClass/index.vue index 1e89098..d38693f 100644 --- a/components/goodClass/index.vue +++ b/components/goodClass/index.vue @@ -12,7 +12,7 @@ :circle="!!label.border_color" :imgSrc="label.icon"> - + @@ -171,6 +173,7 @@ } else { this.isHome = false; } + this.protocol = false; }, onShow() { uni.removeStorageSync('form_type_cart'); @@ -256,6 +259,11 @@ console.log(err) }); }, + agreement(){ + return this.$util.Tips({ + title: '请先阅读并同意协议' + }); + }, // 授权登录 getAuthLogin() { if (!this.protocol) { @@ -343,9 +351,11 @@ // #ifdef MP // 小程序获取手机号码 getphonenumber(e) { + console.log(123123123123123123132) if(e.detail.errMsg == 'getPhoneNumber:fail user deny'){ return false } + if (!this.protocol) { return this.$util.Tips({ title: '请先阅读并同意协议' diff --git a/utils/util.js b/utils/util.js index 4949fe1..7ea6278 100644 --- a/utils/util.js +++ b/utils/util.js @@ -232,11 +232,13 @@ export default { '/pages/index/index' ] .indexOf(url) == -1) { + console.log(123123123123) uni.navigateTo({ url: url }) } else { - uni.reLaunch({ + console.log(123123) + uni.switchTab({ url: url }) }