From ad86bee5f958c7de8a8dbedbc2f0bfc676bb82ab Mon Sep 17 00:00:00 2001 From: TsMask <340112800@qq.com> Date: Thu, 9 May 2024 19:18:21 +0800 Subject: [PATCH] =?UTF-8?q?fix:=20=E5=BC=80=E7=AB=99=E9=A1=B5=E9=9D=A2?= =?UTF-8?q?=E5=90=8C=E6=AD=A5=E5=85=AC=E5=85=B1=E5=8F=82=E6=95=B0=E9=85=8D?= =?UTF-8?q?=E7=BD=AE=EF=BC=8C=E4=BC=98=E5=8C=96=E9=A1=B5=E9=9D=A2=E6=A0=B7?= =?UTF-8?q?=E5=BC=8F?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- .../quick-start/components/NeInfoConfig.vue | 110 ++--- .../components/NeInfoConfigPara5G.vue | 396 +++++------------- .../components/NeInfoSoftwareInstall.vue | 4 +- .../components/NeInfoSoftwareLicense.vue | 4 +- 4 files changed, 146 insertions(+), 368 deletions(-) diff --git a/src/views/system/quick-start/components/NeInfoConfig.vue b/src/views/system/quick-start/components/NeInfoConfig.vue index 45deab5e..36b918ff 100644 --- a/src/views/system/quick-start/components/NeInfoConfig.vue +++ b/src/views/system/quick-start/components/NeInfoConfig.vue @@ -72,23 +72,22 @@ function fnTabClose(key: string) { /**新建网元信息 */ function fnTabCreate() { - const neType = 'NE'; - const neId = '001' + new Date().getMilliseconds(); + const neId = `${new Date().getMilliseconds()}`.padStart(3, '0'); tabState.panes.push({ - key: `${neType}@${neId}`, + key: `New@${neId}`, data: { id: undefined, neId: neId, - neType: neType, - neName: '', + neType: '', + neName: `New_${neId}`, ip: '', port: 33030, pvFlag: 'PNF', - rmUid: `4400HX1${neType}001`, + rmUid: `0000XXNew${neId}`, neAddress: '', - dn: '', - vendorName: '', - province: '', + dn: '-', + vendorName: '-', + province: '-', // 主机 hosts: [ { @@ -121,7 +120,7 @@ function fnTabCreate() { }, status: false, }); - tabState.activeKey = `${neType}@${neId}`; + tabState.activeKey = `New@${neId}`; } /** @@ -220,6 +219,8 @@ function fnSaveFinish(pane: any) { console.log('Success:', pane); tabState.confirmLoading = true; const from = toRaw(pane); + from.rmUid = `0000XX${from.neType}${from.neId}`; // 4400HX1AMF001 + from.neName = `${from.neType}_${from.neId}`; // AMF_001 const result = from.id ? updateNeInfo(from) : addNeInfo(from); const hide = message.loading(t('common.loading'), 0); result @@ -228,12 +229,13 @@ function fnSaveFinish(pane: any) { if (res.data) { pane.id = res.data; } - tabState.panes.findIndex; const tabItem = tabState.panes.find( tab => tab.key === tabState.activeKey ); if (tabItem) { + tabItem.status = false; + tabItem.data.neName = from.neName; tabItem.status = true; } message.success({ @@ -245,6 +247,8 @@ function fnSaveFinish(pane: any) { tab => tab.key === tabState.activeKey ); if (tabItem) { + tabItem.status = true; + tabItem.data.neName = from.neName; tabItem.status = false; } message.error({ @@ -365,7 +369,7 @@ onMounted(() => { @@ -414,28 +418,6 @@ onMounted(() => { - - - - - PNF - - - VNF - - - - - - - { v-model:value="pane.data.neId" allow-clear :placeholder="t('common.inputPlease')" - :maxlength="32" - > - - - - - + + + + {{ t('views.configManage.neManage.neIdTip') }} + + + + @@ -534,35 +507,6 @@ onMounted(() => { - - - - - - - {{ t('views.ne.neInfo.rmUID') }} - - - - - - - - {{ t('views.ne.neInfo.hostConfig') }} @@ -736,7 +680,7 @@ onMounted(() => {