Commit 2fcce67b authored by linwenqing's avatar linwenqing

Merge branch 'dev-fix-auth' into test

parents bfca8aa6 66456c98
...@@ -22,7 +22,7 @@ ...@@ -22,7 +22,7 @@
<view class="target"> <view class="target">
<text class="tips">想要轻松考过,首选模考大师</text> <text class="tips">想要轻松考过,首选模考大师</text>
</view> </view>
<view class="text-area"> <view class="text-area" @click.capture="loadLogin">
<button class="bottom" type="primary" @tap="wxLogin">授权登录</button> <button class="bottom" type="primary" @tap="wxLogin">授权登录</button>
</view> </view>
</view> </view>
...@@ -50,6 +50,12 @@ export default { ...@@ -50,6 +50,12 @@ export default {
} }
}, },
methods: { methods: {
loadLogin() {
uni.showLoading({
title: '加载中..',
mask: true,
})
},
wxLogin() { wxLogin() {
// 获取code 小程序专有,用户登录凭证。 // 获取code 小程序专有,用户登录凭证。
uni.getUserProfile({ uni.getUserProfile({
...@@ -103,6 +109,7 @@ export default { ...@@ -103,6 +109,7 @@ export default {
title: '用户拒绝授权', title: '用户拒绝授权',
showCancel: false, showCancel: false,
}) })
uni.hideLoading()
}, },
}) })
}, },
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment