sc
This commit is contained in:
@@ -34,9 +34,7 @@ router.beforeEach(async (to, from, next) => {
|
|||||||
// next({ path: '/' })
|
// next({ path: '/' })
|
||||||
if (to.query?.tenantId && to.query?.appId) {
|
if (to.query?.tenantId && to.query?.appId) {
|
||||||
setApp(to.query.tenantId, to.query.appId)
|
setApp(to.query.tenantId, to.query.appId)
|
||||||
// setTimeout(() => {
|
await waitTime(1500)
|
||||||
// next({ path: '/' })
|
|
||||||
// }, 1500)
|
|
||||||
}
|
}
|
||||||
next({ path: '/' })
|
next({ path: '/' })
|
||||||
} else {
|
} else {
|
||||||
@@ -80,6 +78,14 @@ router.beforeEach(async (to, from, next) => {
|
|||||||
}
|
}
|
||||||
})
|
})
|
||||||
|
|
||||||
|
async function waitTime(seconds) {
|
||||||
|
return new Promise((resolve) => {
|
||||||
|
setTimeout(() => {
|
||||||
|
resolve()
|
||||||
|
}, seconds)
|
||||||
|
})
|
||||||
|
}
|
||||||
|
|
||||||
function setApp(tenantId, appId) {
|
function setApp(tenantId, appId) {
|
||||||
setTenantId(tenantId)
|
setTenantId(tenantId)
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user