代码优化

This commit is contained in:
BianLzhaoMin 2024-09-18 08:59:29 +08:00
parent ebceeaf823
commit 7eb7701512
1 changed files with 17 additions and 5 deletions

View File

@ -9,6 +9,7 @@ export default {
return {
// url: '/new-page' //
jumpUrl: '',
ENV: process.env.VUE_APP_ENV, // 线
}
},
created() {
@ -24,11 +25,22 @@ export default {
},
methods: {
openNewWindow() {
window.open(
`${this.jumpUrl}/index01.html?token=` +
localStorage.getItem('token'),
'_blank',
)
if (this.ENV === 'production-nw') {
window.open(
`${
this.jumpUrl
}/bigScrap/Home/index?token=${localStorage.getItem(
'token',
)}`,
'_blank',
)
} else {
window.open(
`${this.jumpUrl}/screen/Home/index?token=` +
localStorage.getItem('token'),
'_blank',
)
}
},
},
}