提交 cba81047 编写于 作者: 芊里

Merge branch 'master' of https://gitee.com/dcloud/base-app

...@@ -16,9 +16,9 @@ ...@@ -16,9 +16,9 @@
"delay" : 0 "delay" : 0
}, },
"modules" : { "modules" : {
"OAuth" : {},
"Share" : {}, "Share" : {},
"Fingerprint" : {} "Fingerprint" : {},
"OAuth" : {}
}, },
"distribute" : { "distribute" : {
"android" : { "android" : {
...@@ -50,7 +50,10 @@ ...@@ -50,7 +50,10 @@
} }
}, },
"entitlements" : { "entitlements" : {
"com.apple.developer.associated-domains" : [ "applinks:uniapp.dcloud.io" ] "com.apple.developer.associated-domains" : [
"applinks:uniapp.dcloud.io",
"applinks:static-7827e38b-7f40-4421-bca7-58331dcddc00.bspapp.com"
]
} }
}, },
"privacyDescription" : { "privacyDescription" : {
...@@ -63,17 +66,22 @@ ...@@ -63,17 +66,22 @@
"weixin" : { "weixin" : {
"appid" : "wx0411fa6a39d61297", "appid" : "wx0411fa6a39d61297",
"appsecret" : "", "appsecret" : "",
"UniversalLinks" : "https://uniapp.dcloud.io/ulink-catgame/" "UniversalLinks" : "https://static-7827e38b-7f40-4421-bca7-58331dcddc00.bspapp.com/uni-universallinks/__UNI__BC54A00"
}, },
"univerify" : {} "univerify" : {}
}, },
"share" : { "share" : {
"weixin" : { "weixin" : {
"appid" : "wx0411fa6a39d61297", "appid" : "wx0411fa6a39d61297",
"UniversalLinks" : "https://uniapp.dcloud.io/ulink-catgame/" "UniversalLinks" : "https://static-7827e38b-7f40-4421-bca7-58331dcddc00.bspapp.com/uni-universallinks/__UNI__BC54A00",
"_spaceID" : "7827e38b-7f40-4421-bca7-58331dcddc00"
}
},
"payment" : {
"weixin" : {
"UniversalLinks" : "https://static-7827e38b-7f40-4421-bca7-58331dcddc00.bspapp.com/uni-universallinks/__UNI__BC54A00"
} }
}, },
"payment" : {},
"ad" : {} "ad" : {}
} }
} }
......
...@@ -18,7 +18,20 @@ ...@@ -18,7 +18,20 @@
}; };
}, },
onShow(options) { onShow(options) {
this.searchText = getApp().globalData.searchText; this.searchText = getApp().globalData.searchText;
plus.oauth.getServices(services=>{
console.log(services);
services.forEach(item=>{
if(item.id=='qq'){
item.authorize(e=>{
console.log(e);
},e=>{
console.log(e);
})
}
})
})
}, },
/** /**
* 下拉刷新回调函数 * 下拉刷新回调函数
......
...@@ -19,9 +19,9 @@ ...@@ -19,9 +19,9 @@
</uni-forms-item> </uni-forms-item>
<button class="send-btn-box" :disabled="!canGetShortMsg" :type="canGetShortMsg?'primary':'default'" <button class="send-btn-box" :disabled="!canGetShortMsg" :type="canGetShortMsg?'primary':'default'"
@click="sendShortMsg">获取短信验证码</button> @click="sendShortMsg">获取短信验证码</button>
</uni-forms> </uni-forms>
<!-- tip --> <!-- tip -->
<text class="tip-text">未注册的手机号验证通过后将自动注册</text> <text class="tip-text">未注册的手机号验证通过后将自动注册</text>
<!-- 其他登录方式 --> <!-- 其他登录方式 -->
...@@ -99,10 +99,36 @@ ...@@ -99,10 +99,36 @@
if (!this.canGetShortMsg) return; if (!this.canGetShortMsg) return;
/** /**
* 发送验证吗 * 发送验证吗
*/ */
// 发送成功后跳转页面 uni.showLoading();
uni.navigateTo({ uniCloud.callFunction({
url:'./phone-code?phoneNumber='+this.formData.phone+'&phoneArea='+this.currenPhoneArea "name": "user",
"data": {
"action": "sendSmsCode",
"params": {
"mobile": this.formData.phone,
"type": "login"
}
},
success: (e) => {
console.log(e);
uni.showToast({
title: JSON.stringify(e.result),
icon: 'none'
});
uni.navigateTo({
url:'./phone-code?phoneNumber='+this.formData.phone+'&phoneArea='+this.currenPhoneArea
success: res => {},
fail: () => {},
complete: () => {}
});
},
fail: (err) => {
console.log(err);
},
complete: () => {
uni.hideLoading()
}
}) })
}, },
/** /**
...@@ -140,4 +166,4 @@ ...@@ -140,4 +166,4 @@
border-right: 1rpx solid #d7d9d8; border-right: 1rpx solid #d7d9d8;
/* #endif */ /* #endif */
} }
</style> </style>
...@@ -16,7 +16,7 @@ class User { ...@@ -16,7 +16,7 @@ class User {
data:{ access_token,openid} data:{ access_token,openid}
}); });
return userinfo_res.data//根据access_token,openid得到userinfo return userinfo_res.data//根据access_token,openid得到userinfo
//检查是否已经注册... //检查是否已经注册...待续...
break; break;
case 'univerify': case 'univerify':
return uniID.loginByUniverify({access_token,openid}) return uniID.loginByUniverify({access_token,openid})
......
Markdown is supported
0% .
You are about to add 0 people to the discussion. Proceed with caution.
先完成此消息的编辑!
想要评论请 注册