userId免登录 sn存储
This commit is contained in:
parent
49828737eb
commit
aae818d9c8
@ -524,10 +524,13 @@ onMounted(async () => {
|
|||||||
if (window.location.href.indexOf("userId") != -1) {
|
if (window.location.href.indexOf("userId") != -1) {
|
||||||
console.log("免登录跳转进来了吗----", window.location.href.indexOf("userId"));
|
console.log("免登录跳转进来了吗----", window.location.href.indexOf("userId"));
|
||||||
const newUserId = window.location.href.split("userId=")[1].split("&")[0];
|
const newUserId = window.location.href.split("userId=")[1].split("&")[0];
|
||||||
|
const projectSn = window.location.href.split("sn=")[1].split("&")[0];
|
||||||
const data: any = await jumpLargeByUserIdApi({ userId: newUserId });
|
const data: any = await jumpLargeByUserIdApi({ userId: newUserId });
|
||||||
console.log("跳转请求的数据----", data.result);
|
console.log("跳转请求的数据----", data.result);
|
||||||
if (data.result.sn) {
|
if (data.result.sn) {
|
||||||
store.setSN(data.result.sn);
|
const accountTypeList = [2, 3, 4, 7];
|
||||||
|
const sn = accountTypeList.includes(data.result.accountType) ? projectSn : data.result.sn;
|
||||||
|
store.setSN(sn);
|
||||||
}
|
}
|
||||||
store.setToken(data.result.token);
|
store.setToken(data.result.token);
|
||||||
store.setAccount(data.result.account);
|
store.setAccount(data.result.account);
|
||||||
|
|||||||
Loading…
x
Reference in New Issue
Block a user