From 3c1ee63359ad87f252b4ef1e19d587260887f076 Mon Sep 17 00:00:00 2001 From: TsMask <340112800@qq.com> Date: Tue, 30 Jul 2024 18:23:51 +0800 Subject: [PATCH] =?UTF-8?q?fix:=20=E5=BC=80=E7=AB=99=E7=BD=91=E5=85=83?= =?UTF-8?q?=E5=AE=89=E8=A3=85=E4=BF=A1=E6=81=AF=E4=BF=9D=E5=AD=98=E8=A7=A6?= =?UTF-8?q?=E5=8F=91=E6=93=8D=E4=BD=9C=E4=B8=8D=E4=B8=80=E8=87=B4?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../system/quick-start/components/NeInfoConfig.vue | 12 ++++++------ 1 file changed, 6 insertions(+), 6 deletions(-) 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'); });