fix(嵌入式): 编辑数据集和数据集时页面无响应,控制台报错

This commit is contained in:
dataeaseShu
2025-05-14 11:24:20 +08:00
committed by xuwei-fit2cloud
parent 8eca7a8068
commit 2ef24cc06e
2 changed files with 7 additions and 2 deletions

View File

@@ -86,7 +86,12 @@ const appStore = useAppStoreWithOut()
const embeddedStore = useEmbedded()
const { t } = useI18n()
const route = useRoute()
const { push } = useRouter()
const { push } = useRouter() || {
push: val => {
if (embeddedStore.getToken) return
window.location.href = val as string
}
}
const quotaTableHeight = ref(238)
const creatDsFolder = ref()
const editCalcField = ref(false)

View File

@@ -1051,7 +1051,7 @@ onMounted(() => {
loadInit()
listDs()
setSupportSetKey()
const { opt } = router.currentRoute.value.query
const { opt } = router?.currentRoute?.value?.query || {}
if (opt && opt === 'create') {
datasourceEditor.value.init(null, null, null, isSupportSetKey.value)
}