From 4e3e07f603de97d8c593d743a74f84325c87845c Mon Sep 17 00:00:00 2001 From: TsMask <340112800@qq.com> Date: Mon, 6 Nov 2023 16:38:25 +0800 Subject: [PATCH] =?UTF-8?q?fix:=20=E9=85=8D=E7=BD=AE=E5=8F=82=E6=95=B0?= =?UTF-8?q?=E4=B8=8B=E6=8B=89=E9=80=89=E6=8B=A9=E5=AE=BD=E5=BA=A6=E5=9B=BA?= =?UTF-8?q?=E5=AE=9A?= MIME-Version: 1.0 Content-Type: text/plain; charset=UTF-8 Content-Transfer-Encoding: 8bit --- src/api/configManage/configParam.ts | 2 +- src/views/configManage/configParam/index.vue | 34 ++- .../components/array-children.vue | 64 ----- .../configManage/configParamTree/index.vue | 243 ++++++------------ 4 files changed, 95 insertions(+), 248 deletions(-) delete mode 100644 src/views/configManage/configParamTree/components/array-children.vue diff --git a/src/api/configManage/configParam.ts b/src/api/configManage/configParam.ts index bed1a69d..d885f021 100644 --- a/src/api/configManage/configParam.ts +++ b/src/api/configManage/configParam.ts @@ -18,7 +18,7 @@ export async function getParamConfigTopTab(neType: string) { url: `/api/rest/databaseManagement/v1/elementType/omc_db/objectType/param_config`, method: 'get', params: { - SQL: `SELECT top_display,top_tag FROM param_config WHERE ne_type = '${neType}'`, + SQL: `SELECT top_display,top_tag,method FROM param_config WHERE ne_type = '${neType}'`, }, }); // 解析数据 diff --git a/src/views/configManage/configParam/index.vue b/src/views/configManage/configParam/index.vue index f920e757..a4dab75c 100644 --- a/src/views/configManage/configParam/index.vue +++ b/src/views/configManage/configParam/index.vue @@ -1084,11 +1084,7 @@ onMounted(() => { - + { v-model:value="tableState.editRecord['value']" :min="0" :max="65535" + style="min-width: 180px;" > { v-else-if="record['type'] === 'enum'" v-model:value="tableState.editRecord['value']" :allow-clear="true" + style="min-width: 180px;" > { v-show="tableState.type === 'array'" class="table" row-key="index" - :columns="tableState.arrayColumns" + :columns="tab.method === 'get' ? tableState.arrayColumns.filter((s:any)=>s.key !== 'index') : tableState.arrayColumns" :loading="tableState.loading" :data-source="tableState.arrayData" :size="tableState.size" @@ -1229,7 +1227,12 @@ onMounted(() => { v-model:expanded-row-keys="tableState.arrayChildExpandKeys" > - + {{ t('common.addText') }} @@ -1319,6 +1322,7 @@ onMounted(() => { v-model:value=" tableState.editRecord[text.name]['value'] " + style="width: 100%" > { " :min="0" :max="65535" + style="width: 100%" > { v-else-if="text['type'] === 'enum'" v-model:value=" tableState.editRecord[text.name]['value'] - " - :allow-clear="true" + " + style="min-width: 180px;" > {{ k }} @@ -1490,6 +1495,7 @@ onMounted(() => { 'value' ] " + style="width: 100%;" > { " :min="0" :max="65535" + style="width: 100%;" > { ] " :allow-clear="true" + style="min-width: 180px;" > {{ k }} diff --git a/src/views/configManage/configParamTree/components/array-children.vue b/src/views/configManage/configParamTree/components/array-children.vue deleted file mode 100644 index 23812331..00000000 --- a/src/views/configManage/configParamTree/components/array-children.vue +++ /dev/null @@ -1,64 +0,0 @@ - - - - - {{ props }} - - - - diff --git a/src/views/configManage/configParamTree/index.vue b/src/views/configManage/configParamTree/index.vue index ca295e5a..a4bf8b1c 100644 --- a/src/views/configManage/configParamTree/index.vue +++ b/src/views/configManage/configParamTree/index.vue @@ -20,7 +20,6 @@ import { toRaw } from 'vue'; import { regExpIPv4, regExpIPv6 } from '@/utils/regular-utils'; import { DataNode, EventDataNode } from 'ant-design-vue/lib/tree'; import { ColumnsType } from 'ant-design-vue/lib/table'; -import ArrayChildren from './components/array-children.vue'; const { t } = useI18n(); /**网元参数 */ @@ -990,34 +989,6 @@ function ruleVerification(row: Record): (string | boolean)[] { return result; } -/**网元重新加载状态 */ -let neReloadLoading = ref(false); - -/**网元重新加载 */ -function fnNeReload() { - // 获取数据 - const neType = neTypeSelect.value[0]; - const neId = neTypeSelect.value[1]; - neReloadLoading.value = true; - updateNeConfigReload(neType, neId) - .then(res => { - if (res.code === RESULT_CODE_SUCCESS) { - message.success({ - content: `网元重新加载完成`, - duration: 3, - }); - } else { - message.error({ - content: `网元重新加载失败`, - duration: 3, - }); - } - }) - .finally(() => { - neReloadLoading.value = false; - }); -} - onMounted(() => { // 获取网元网元列表 useNeInfoStore() @@ -1307,32 +1278,7 @@ let modalArrayChildState: ModalArrayChildStateType = reactive({ - - - - - - 重新载入 - - - - + @@ -1367,7 +1313,7 @@ let modalArrayChildState: ModalArrayChildStateType = reactive({ {{ state.title }} - 左侧命令导航中选择要操作项! + 左侧配置中选择要操作项! @@ -1439,14 +1385,14 @@ let modalArrayChildState: ModalArrayChildStateType = reactive({ ) " v-model:value="state.editRecord['value']" - :placeholder="record['filter']" + style="min-width: 200px" > - - - - - - {{ item.comment }} - - - {{ state.editRecord[item.name] }} - + + + {{ item.comment }} + + + {{ state.editRecord[item.name] }} + + + + + + - - - - - - - {{ k }} - - - - - - 详情 - - - {{ `${item.value}` }} - - - - - - + {{ k }} + + + + + + 详情 + + + {{ `${item.value}` }} + + + + - - - - - - - - - 重新载入 - - - - +