From 1d7c2b304f69914a18cdea93b6c428fa7124c4a5 Mon Sep 17 00:00:00 2001 From: dataeaseShu Date: Tue, 24 Dec 2024 09:58:08 +0800 Subject: [PATCH] =?UTF-8?q?fix(=E5=B5=8C=E5=85=A5=E5=BC=8F):=20=E5=B5=8C?= =?UTF-8?q?=E5=85=A5=E4=BB=AA=E8=A1=A8=E6=9D=BF=E8=AE=BE=E8=AE=A1=E5=99=A8?= =?UTF-8?q?=EF=BC=8C=E4=BB=AA=E8=A1=A8=E6=9D=BF=E7=BC=96=E8=BE=91=E9=A1=B5?= =?UTF-8?q?=E9=9D=A2=E7=82=B9=E5=87=BB=E6=96=B0=E9=A1=B5=E9=9D=A2=E9=A2=84?= =?UTF-8?q?=E8=A7=88=E6=8A=A5=E9=94=99404?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- core/core-frontend/src/components/dashboard/DbToolbar.vue | 7 +++++-- core/core-frontend/src/views/share/share/ShareGrid.vue | 7 ++++++- 2 files changed, 11 insertions(+), 3 deletions(-) diff --git a/core/core-frontend/src/components/dashboard/DbToolbar.vue b/core/core-frontend/src/components/dashboard/DbToolbar.vue index 10e6cd2fa2..bd35b336ff 100644 --- a/core/core-frontend/src/components/dashboard/DbToolbar.vue +++ b/core/core-frontend/src/components/dashboard/DbToolbar.vue @@ -140,7 +140,10 @@ const previewOuter = () => { return } canvasSave(() => { - const url = '#/preview?dvId=' + dvInfo.value.id + '&ignoreParams=true' + let url = '#/preview?dvId=' + dvInfo.value.id + '&ignoreParams=true' + if (embeddedStore.baseUrl) { + url = `${embedded.baseUrl}${url}`.replaceAll('\/\/#', '\/#') + } const newWindow = window.open(url, '_blank') initOpenHandler(newWindow) }) @@ -650,7 +653,7 @@ const initOpenHandler = newWindow => { - + {{ t('work_branch.new_page_preview') }} diff --git a/core/core-frontend/src/views/share/share/ShareGrid.vue b/core/core-frontend/src/views/share/share/ShareGrid.vue index 42e02fad34..49141599b5 100644 --- a/core/core-frontend/src/views/share/share/ShareGrid.vue +++ b/core/core-frontend/src/views/share/share/ShareGrid.vue @@ -10,6 +10,7 @@ import { useI18n } from '@/hooks/web/useI18n' import { ref, reactive, watch, computed } from 'vue' import GridTable from '@/components/grid-table/src/GridTable.vue' import request from '@/config/axios' +import { useEmbedded } from '@/store/modules/embedded' import dayjs from 'dayjs' import { propTypes } from '@/utils/propTypes' import ShareHandler from './ShareHandler.vue' @@ -23,6 +24,7 @@ const props = defineProps({ const { wsCache } = useCache('localStorage') const { t } = useI18n() const interactiveStore = interactiveStoreWithOut() +const embeddedStore = useEmbedded() const busiDataMap = computed(() => interactiveStore.getData) const panelKeyword = ref() @@ -47,6 +49,9 @@ const triggerFilterPanel = () => { } const preview = id => { const routeUrl = `/#/preview?dvId=${id}` + if (embeddedStore.baseUrl) { + routeUrl = `${embedded.baseUrl}${routeUrl}`.replaceAll('\/\/#', '\/#') + } window.open(routeUrl, '_blank') } const formatterTime = (_, _column, cellValue) => { @@ -235,7 +240,7 @@ watch(