Merge pull request 'zmr' (#45) from zmr into master

Reviewed-on: http://git.luyuan.tk/luyuan/deming/pulls/45
This commit was merged in pull request #45.
This commit is contained in:
2020-07-03 10:59:01 +08:00

View File

@@ -50,7 +50,7 @@
<image src="../../static/pageA/weixin.png" class="image"></image>
<view>微信登录</view>
</view>
<view class="rect_butoon" @click="show = false">取消</view>
<view class="rect_butoon" @click="show = false">取消</view>
</view>
</view>
</u-mask>
@@ -139,7 +139,7 @@
return false;
}
if( this.sms_code == ''){
this.$refs.uToast.show({
this.$refs.uToast.show({
title: '验证码不能为空',
type: 'error'
})
@@ -152,18 +152,27 @@
console.log(res)
// console.log(res)
if (res.errCode == 0) {
// 缓存用户的信息
uni.setStorage({
key: 'user_info',
data: res.data,
success: function() {
console.log('success');
// 跳转首页
uni.navigateTo({
url : '/pageA/topick/topick'
})
}
});
if(res.data == ''){
this.$refs.uToast.show({
title: res.message,
type: 'error'
})
return false
}else{
// 缓存用户的信息
uni.setStorage({
key: 'user_info',
data: res.data,
success: function() {
console.log('success');
// 跳转首页
uni.navigateTo({
url : '/pageA/topick/topick'
})
}
});
}
// 存储接口请求所需token
uni.setStorage({
@@ -183,7 +192,7 @@
type: 'error'
})
}
})
})
},
// qq授权登录
rect_qq() {