commit
04da24d86c
17 changed files with 167 additions and 85 deletions
@ -0,0 +1,41 @@ |
|||||||
|
<template> |
||||||
|
<div></div> |
||||||
|
</template> |
||||||
|
|
||||||
|
<script> |
||||||
|
import {mapGetters} from "vuex"; |
||||||
|
|
||||||
|
export default { |
||||||
|
name: "scada-sso", |
||||||
|
data() { |
||||||
|
return { |
||||||
|
loginForm: { |
||||||
|
token: null |
||||||
|
} |
||||||
|
}; |
||||||
|
}, |
||||||
|
created() { |
||||||
|
}, |
||||||
|
mounted() { |
||||||
|
this.handleLogin(); |
||||||
|
}, |
||||||
|
computed: { |
||||||
|
...mapGetters(["tagWel"]) |
||||||
|
}, |
||||||
|
props: [], |
||||||
|
methods: { |
||||||
|
handleLogin() { |
||||||
|
let token = this.$route.query.SSOToken; |
||||||
|
this.loginForm.token = token; |
||||||
|
this.$store.dispatch("loginByScada", this.loginForm).then(() => { |
||||||
|
this.$router.push({path: this.tagWel.value}); |
||||||
|
}).catch(() => { |
||||||
|
this.$router.push({path: "/403"}); |
||||||
|
}); |
||||||
|
}, |
||||||
|
} |
||||||
|
}; |
||||||
|
</script> |
||||||
|
|
||||||
|
<style> |
||||||
|
</style> |
Loading…
Reference in new issue