功能调整
parent
e48c0d5106
commit
326bbc8d3e
@ -0,0 +1,25 @@
|
|||||||
|
<template>
|
||||||
|
<div>
|
||||||
|
跳转中...
|
||||||
|
</div>
|
||||||
|
</template>
|
||||||
|
<script>
|
||||||
|
// import * as memberApi from '@/api/user'
|
||||||
|
import * as authApi from "@/utils/auth.js"
|
||||||
|
export default {
|
||||||
|
created(){
|
||||||
|
console.log(this.$route.query.token)
|
||||||
|
if(this.$route.query.token){
|
||||||
|
authApi.setToken(this.$route.query.token)
|
||||||
|
this.$route.push('/')
|
||||||
|
// localStorage.setItem("token",this.$route.query.token)
|
||||||
|
// memberApi.info().then(res=>{
|
||||||
|
// if(res.code === 200){
|
||||||
|
// authApi.setInfo(res.data)
|
||||||
|
|
||||||
|
// }
|
||||||
|
// })
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
</script>
|
@ -0,0 +1,22 @@
|
|||||||
|
<template>
|
||||||
|
|
||||||
|
</template>
|
||||||
|
<script>
|
||||||
|
import * as memberApi from '@/api/member'
|
||||||
|
import * as authApi from "@/utils/auth.js"
|
||||||
|
export default {
|
||||||
|
created(){
|
||||||
|
console.log(this.$route.query.token)
|
||||||
|
if(this.$route.query.token){
|
||||||
|
localStorage.setItem("token",this.$route.query.token)
|
||||||
|
memberApi.info().then(res=>{
|
||||||
|
console.log(res)
|
||||||
|
if(res.code === 200){
|
||||||
|
authApi.setInfo(res.data)
|
||||||
|
this.$router.push('/')
|
||||||
|
}
|
||||||
|
})
|
||||||
|
}
|
||||||
|
}
|
||||||
|
}
|
||||||
|
</script>
|
Loading…
Reference in New Issue