Update login
This commit is contained in:
@@ -45,6 +45,8 @@ export default {
|
|||||||
}
|
}
|
||||||
if (this.$route.query.link) this.$store.commit('updateLink', { link: this.$route.query.link });
|
if (this.$route.query.link) this.$store.commit('updateLink', { link: this.$route.query.link });
|
||||||
if (this.$route.query.iframe) this.$store.commit('updateStore', { name: 'iframe', data: this.$route.query.iframe });
|
if (this.$route.query.iframe) this.$store.commit('updateStore', { name: 'iframe', data: this.$route.query.iframe });
|
||||||
|
if (this.$route.query.module) this.$store.commit('updateStore', { name: 'module', data: this.$route.query.module });
|
||||||
|
|
||||||
},
|
},
|
||||||
computed: {
|
computed: {
|
||||||
ismobile: {
|
ismobile: {
|
||||||
|
|||||||
@@ -244,6 +244,14 @@ export default {
|
|||||||
this.$store.commit('updateViewPort', { viewport: val });
|
this.$store.commit('updateViewPort', { viewport: val });
|
||||||
},
|
},
|
||||||
},
|
},
|
||||||
|
module: {
|
||||||
|
get: function () {
|
||||||
|
return this.$store.state['module'];
|
||||||
|
},
|
||||||
|
set: function (val) {
|
||||||
|
this.$store.commit('updateStore', { name: 'module', data: val });
|
||||||
|
},
|
||||||
|
},
|
||||||
},
|
},
|
||||||
methods: {
|
methods: {
|
||||||
checkError() {
|
checkError() {
|
||||||
@@ -373,7 +381,7 @@ export default {
|
|||||||
// let userapps = await this.$getdata('userapps', { user: data.id, apps__code: this.module }, undefined, true);
|
// let userapps = await this.$getdata('userapps', { user: data.id, apps__code: this.module }, undefined, true);
|
||||||
// if (!userapps) return this.$router.push('/welcome');
|
// if (!userapps) return this.$router.push('/welcome');
|
||||||
// }
|
// }
|
||||||
|
|
||||||
this.login = data; //store login
|
this.login = data; //store login
|
||||||
if (this.$store.state.link) {
|
if (this.$store.state.link) {
|
||||||
let ele = this.$copy(data);
|
let ele = this.$copy(data);
|
||||||
@@ -393,7 +401,7 @@ export default {
|
|||||||
if (data.type === 3 && link.indexOf('y99') >= 0) {
|
if (data.type === 3 && link.indexOf('y99') >= 0) {
|
||||||
link = link.indexOf('dev') >= 0 ? '' : '';
|
link = link.indexOf('dev') >= 0 ? '' : '';
|
||||||
}
|
}
|
||||||
let href = `${link}?username=${ele.username}&token=${ele.token}&fullname=${ele.fullname}&userid=${ele.id}`;
|
let href = `${link}?email=${ele.email}&token=${ele.token}&fullname=${ele.fullname}&userid=${ele.id}`;
|
||||||
if (ele.avatar) href = `${href}&avatar=${ele.avatar}`;
|
if (ele.avatar) href = `${href}&avatar=${ele.avatar}`;
|
||||||
window.location.href = href;
|
window.location.href = href;
|
||||||
} else this.redirectUrl();
|
} else this.redirectUrl();
|
||||||
|
|||||||
@@ -65,7 +65,8 @@ export const state = () => ({
|
|||||||
pagedata3: undefined,
|
pagedata3: undefined,
|
||||||
pagedata4: undefined,
|
pagedata4: undefined,
|
||||||
settings: [],
|
settings: [],
|
||||||
iframe: undefined
|
iframe: undefined,
|
||||||
|
module: undefined,
|
||||||
})
|
})
|
||||||
|
|
||||||
export const mutations = {
|
export const mutations = {
|
||||||
|
|||||||
Reference in New Issue
Block a user