diff --git a/src/views/system/quick-start/components/NeInfoConfig.vue b/src/views/system/quick-start/components/NeInfoConfig.vue index 66e2359e..cbe0b7d2 100644 --- a/src/views/system/quick-start/components/NeInfoConfig.vue +++ b/src/views/system/quick-start/components/NeInfoConfig.vue @@ -396,10 +396,6 @@ function fnStepPrev() { /**下一步操作 先全部集体发过去请求新增 */ function fnStepNext(stepName: 'NeInfoConfigPara5G') { - let promises = tabState.panes.map((item: any) => { - return item.id ? updateNeInfo(item) : addNeInfo(item); - }); - if (stepName === 'NeInfoConfigPara5G') { Modal.confirm({ title: t('common.tipTitle'), @@ -408,9 +404,13 @@ function fnStepNext(stepName: 'NeInfoConfigPara5G') { loading: tabState.confirmLoading, }, onOk() { - // 使用 Promise.allSettled 等待所有 Promise 完成 tabState.confirmLoading = true; - Promise.allSettled(promises).finally(() => { + // 使用 Promise.allSettled 等待所有 Promise 完成 + Promise.allSettled( + tabState.panes.map((item: any) => + item.id ? updateNeInfo(item) : addNeInfo(item) + ) + ).finally(() => { tabState.confirmLoading = false; fnToStepName('NeInfoConfigPara5G'); });