Merge pull request 'dist' (#271) from xbx into master
Reviewed-on: http://git.luyuan.tk/luyuan/beelink/pulls/271
This commit is contained in:
commit
ae44e69454
@ -19,13 +19,14 @@ import { useRoute } from "vue-router";
|
|||||||
export default defineComponent(({
|
export default defineComponent(({
|
||||||
setup(){
|
setup(){
|
||||||
const code: any = useRoute().query.code;
|
const code: any = useRoute().query.code;
|
||||||
console.log(code)
|
alert(code)
|
||||||
if(!code){
|
if(!code){
|
||||||
router.push("/")
|
router.push("/")
|
||||||
|
return ;
|
||||||
}
|
}
|
||||||
accessToken(code, 1).then((res: any)=>{
|
accessToken(code, 1).then((res: any)=>{
|
||||||
console.log(res)
|
console.log(res)
|
||||||
authLogin(res.uid, 2).then((res: any)=>{
|
authLogin(res.uid, 1).then((res: any)=>{
|
||||||
if(res.redirect == 1){
|
if(res.redirect == 1){
|
||||||
sessionStorage.setItem('mid',res.memberid);
|
sessionStorage.setItem('mid',res.memberid);
|
||||||
router.push("/sign")
|
router.push("/sign")
|
||||||
|
Loading…
Reference in New Issue
Block a user