|
@@ -15,7 +15,7 @@ export default {
|
|
|
}
|
|
|
|
|
|
const res = await getWxUserInfo({ code: code, userId: localStorage.getItem("userId") })
|
|
|
- console.log(res, '================================')
|
|
|
+ console.log(res, '================================getWxUserInfo')
|
|
|
if (res.body.code == '0') {
|
|
|
console.log('直接走+======', res)
|
|
|
localStorage.setItem("openid", res.body.openId);
|
|
@@ -29,6 +29,7 @@ export default {
|
|
|
Vue.prototype.urlredirect = async function (page) {
|
|
|
const res = await getWxConfig({})
|
|
|
const href = window.location.href
|
|
|
+ // const href = 'https://tianzong.info666.com/'
|
|
|
window.location.href =
|
|
|
`https://open.weixin.qq.com/connect/oauth2/authorize?appid=${res.wxConfig.appId}&redirect_uri=${encodeURIComponent(href)}` + `&response_type=code&scope=snsapi_userinfo&state=STATE&connect_redirect=1#wechat_redirect`;
|
|
|
}
|