feat:【mall 商城】店铺预览时,增加 tenantId

pull/813/head
YunaiV 2025-08-19 09:16:46 +08:00
parent 1a92b97797
commit c93c70a3cb
1 changed files with 2 additions and 1 deletions

View File

@ -34,6 +34,7 @@ import { useTagsViewStore } from '@/store/modules/tagsView'
import { DiyComponentLibrary, PAGE_LIBS } from '@/components/DiyEditor/util' // DIY DiyEditor import { DiyComponentLibrary, PAGE_LIBS } from '@/components/DiyEditor/util' // DIY DiyEditor
import { toNumber } from 'lodash-es' import { toNumber } from 'lodash-es'
import { isEmpty } from '@/utils/is' import { isEmpty } from '@/utils/is'
import { getTenantId } from '@/utils/auth'
/** 装修模板表单 */ /** 装修模板表单 */
defineOptions({ name: 'DiyTemplateDecorate' }) defineOptions({ name: 'DiyTemplateDecorate' })
@ -69,7 +70,7 @@ const getPageDetail = async (id: any) => {
formData.value = await DiyTemplateApi.getDiyTemplateProperty(id) formData.value = await DiyTemplateApi.getDiyTemplateProperty(id)
// //
const domain = import.meta.env.VITE_MALL_H5_DOMAIN const domain = import.meta.env.VITE_MALL_H5_DOMAIN
previewUrl.value = `${domain}/#/pages/index/index?templateId=${formData.value.id}` previewUrl.value = `${domain}?templateId=${formData.value.id}&tenantId=${getTenantId()}`
} finally { } finally {
formLoading.value = false formLoading.value = false
} }