diff --git a/frontend/src/components/business/ms-assertion/comp/ScriptTab.vue b/frontend/src/components/business/ms-assertion/comp/ScriptTab.vue index ae9beed6ba..5083684ce3 100644 --- a/frontend/src/components/business/ms-assertion/comp/ScriptTab.vue +++ b/frontend/src/components/business/ms-assertion/comp/ScriptTab.vue @@ -6,7 +6,7 @@ height: 'calc(100vh - 490px)', }" > - + @@ -33,15 +33,15 @@ const emit = defineEmits<{ (e: 'change', val: ScriptItem): void; // 数据发生变化 }>(); - + function handleChange() { + // eslint-disable-next-line no-use-before-define + emit('change', { ...condition.value }); + } const condition = useVModel(props, 'data', emit); const currentEnvConfig = ref({}); async function initEnvironment() { - try { + if (store.currentId) { currentEnvConfig.value = await getEnvironment(store.currentId); - } catch (error) { - // eslint-disable-next-line no-console - console.log(error); } } /** 向孙组件提供属性 */ diff --git a/frontend/src/components/business/ms-assertion/index.vue b/frontend/src/components/business/ms-assertion/index.vue index 46f04e1113..8dfe038658 100644 --- a/frontend/src/components/business/ms-assertion/index.vue +++ b/frontend/src/components/business/ms-assertion/index.vue @@ -76,13 +76,7 @@ -
- +
- + {{ t('apiTestDebug.manual') }} {{ t('apiTestDebug.quote') }} @@ -672,7 +672,7 @@ if (!result){ dataIndex: 'variableType', slotName: 'variableType', typeOptions: [ - // 全局参数,暂时不上 + // 全局参数,暂时不上 // { // label: t('apiTestDebug.globalParameter'), // value: RequestExtractEnvType.GLOBAL,