授权登录
This commit is contained in:
@@ -25,12 +25,9 @@ export default {
|
|||||||
methods: {
|
methods: {
|
||||||
...mapActions(['autoLogin']),
|
...mapActions(['autoLogin']),
|
||||||
show() {
|
show() {
|
||||||
tools.$getUserProfile().then(data => {
|
|
||||||
this.userData = data.userInfo;
|
|
||||||
this.userPhoneShow = true;
|
|
||||||
})
|
|
||||||
tools.$getLoginCode().then(res => {
|
tools.$getLoginCode().then(res => {
|
||||||
this.code = res.code;
|
this.code = res.code;
|
||||||
|
this.userPhoneShow = true;
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
hide() {
|
hide() {
|
||||||
|
|||||||
@@ -91,6 +91,9 @@ const $getUserProfile = () => {
|
|||||||
lang: 'zh_CN',
|
lang: 'zh_CN',
|
||||||
success: (data) => {
|
success: (data) => {
|
||||||
resolve(data);
|
resolve(data);
|
||||||
|
},
|
||||||
|
fail: (err)=> {
|
||||||
|
console.log(err);
|
||||||
}
|
}
|
||||||
});
|
});
|
||||||
});
|
});
|
||||||
|
|||||||
@@ -303,6 +303,7 @@
|
|||||||
<div class="btn" hover-class="text-hover" @click="submit">提交</div>
|
<div class="btn" hover-class="text-hover" @click="submit">提交</div>
|
||||||
</div>
|
</div>
|
||||||
</div>
|
</div>
|
||||||
|
|
||||||
<AiLogin ref="login" @success="getAuth()"/>
|
<AiLogin ref="login" @success="getAuth()"/>
|
||||||
</div>
|
</div>
|
||||||
</template>
|
</template>
|
||||||
@@ -394,11 +395,8 @@ export default {
|
|||||||
this.travelTypeDict = this.$dict.getDict('EP_travelType')
|
this.travelTypeDict = this.$dict.getDict('EP_travelType')
|
||||||
})
|
})
|
||||||
this.getewayList()
|
this.getewayList()
|
||||||
if(!this.token.length) {
|
if(!this.token) {
|
||||||
this.$refs.login.show()
|
this.$refs.login.show()
|
||||||
} else {
|
|
||||||
this.pageShow = true
|
|
||||||
this.form.gatewayId = decodeURIComponent(o.scene) || ''
|
|
||||||
}
|
}
|
||||||
},
|
},
|
||||||
|
|
||||||
@@ -417,6 +415,8 @@ export default {
|
|||||||
getAuth() {
|
getAuth() {
|
||||||
this.$nextTick(() => {
|
this.$nextTick(() => {
|
||||||
this.token && this.getUserInfo()
|
this.token && this.getUserInfo()
|
||||||
|
this.pageShow = true
|
||||||
|
this.form.gatewayId = decodeURIComponent(o.scene) || ''
|
||||||
})
|
})
|
||||||
},
|
},
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user