fix:修复跳转起始页报错问题

This commit is contained in:
wangsongsole 2022-10-08 16:33:44 +08:00
parent 4da9f126cc
commit da5cc8818c
3 changed files with 17 additions and 5 deletions

View File

@ -407,7 +407,7 @@
sessionStorage.setItem('goodsInfo', JSON.stringify(goodsArr[0]));
sessionStorage.setItem('key', goodsArr[0].key);
sessionStorage.setItem('token', goodsArr[0].token);
window.location.replace(goodsArr[0].type == 1 ? "./exchange.html" : "./index.html");
window.location.replace(goodsArr[0].type == 1 ? "./exchange.html" : "./index.html?id=" + sessionStorage.getItem('linkId'));
return false;
} else if (goodsArr && goodsArr.length >= 1) {
self.goodsNum = true;

View File

@ -163,7 +163,11 @@
this.popStatus = 2
this.popShow = true
if (!this.popShow) {
window.location.replace('./index.html');
/*跳转起始页面*/
let entryLink = sessionStorage.getItem('entryLink');
setTimeout(() => {
window.location.replace(entryLink);
}, 3000);
}
return
}

View File

@ -162,7 +162,7 @@
if (code === -1) {
this.popFunction({ title: '温馨提示', text: message, status: 2, b_text: '我知道了', show: true })
if (!this.popShow) {
window.location.replace('./index.html');
this.toPage()
}
return
}
@ -183,7 +183,7 @@
if (code === -1) {
this.popFunction({ title: '温馨提示', text: message, status: 2, b_text: '我知道了', show: true })
if (!this.popShow) {
window.location.replace('./index.html');
this.toPage()
}
return
}
@ -223,7 +223,7 @@
if (code === -1) {
this.popFunction({ title: '温馨提示', text: message, status: 2, b_text: '我知道了', show: true })
if (!this.popShow) {
window.location.replace('./index.html');
this.toPage()
}
return
}
@ -238,6 +238,14 @@
})
},
/*跳转起始页面*/
toPage () {
let entryLink = sessionStorage.getItem('entryLink');
setTimeout(() => {
window.location.replace(entryLink);
}, 3000);
},
/* 弹窗回调 */
backFunction (type) {
if (this.bottomText === '点击复制' && type) {