Skip to content

Commit 27ff18b

Browse files
committed
fix/model-driven
1 parent f9895c3 commit 27ff18b

1 file changed

Lines changed: 3 additions & 2 deletions

File tree

  • packages/plugins/model-manager/src

packages/plugins/model-manager/src/Main.vue

Lines changed: 3 additions & 2 deletions
Original file line numberDiff line numberDiff line change
@@ -70,7 +70,7 @@ import { ref, reactive, provide, computed, onMounted } from 'vue'
7070
import { TinySearch, Modal, TinyButton } from '@opentiny/vue'
7171
import { IconSearch } from '@opentiny/vue-icon'
7272
import { PluginPanel, SvgButton, SearchEmpty } from '@opentiny/tiny-engine-common'
73-
import { useLayout } from '@opentiny/tiny-engine-meta-register'
73+
import { useLayout, useEnv } from '@opentiny/tiny-engine-meta-register'
7474
import ModelSetting, { openModelSettingPanel, closeModelSettingPanel } from './components/ModelSetting.vue'
7575
import { getModelList, deleteModel, getModelSql, getModelSqlById } from './composable/useModelManager'
7676
@@ -86,6 +86,7 @@ defineProps({
8686
const emit = defineEmits(['close'])
8787
8888
const { PLUGIN_NAME } = useLayout()
89+
const { VITE_ORIGIN } = useEnv()
8990
const TinyIconSearch = IconSearch()
9091
const selectedModel = ref(null) // 当前选中的模型
9192
// 模型数据列表,包含模型及其字段
@@ -135,7 +136,7 @@ const handleAddModel = () => {
135136
id: null,
136137
nameCn: '',
137138
nameEn: '',
138-
modelUrl: `${import.meta.env.VITE_ORIGIN}/platform-center/api/model-data`,
139+
modelUrl: `${VITE_ORIGIN}/platform-center/api/model-data`,
139140
description: '',
140141
parameters: []
141142
}

0 commit comments

Comments
 (0)