fix: 默认选择AMF找不到选首个
This commit is contained in:
@@ -1071,9 +1071,12 @@ onMounted(() => {
|
|||||||
);
|
);
|
||||||
// 默认选择AMF
|
// 默认选择AMF
|
||||||
const item = neCascaderOtions.value.find(s => s.value === 'AMF');
|
const item = neCascaderOtions.value.find(s => s.value === 'AMF');
|
||||||
if (item) {
|
if (item && item.children) {
|
||||||
const info = item.children[0];
|
const info = item.children[0];
|
||||||
neTypeSelect.value = [info.neType, info.neId];
|
neTypeSelect.value = [info.neType, info.neId];
|
||||||
|
} else {
|
||||||
|
const info = neCascaderOtions.value[0].children[0];
|
||||||
|
neTypeSelect.value = [info.neType, info.neId];
|
||||||
}
|
}
|
||||||
fnGetParamConfigTopTab();
|
fnGetParamConfigTopTab();
|
||||||
}
|
}
|
||||||
@@ -1420,8 +1423,7 @@ onMounted(() => {
|
|||||||
@click.prevent="arrayChildExpand(record['index'], text)"
|
@click.prevent="arrayChildExpand(record['index'], text)"
|
||||||
v-else-if="Array.isArray(text.array)"
|
v-else-if="Array.isArray(text.array)"
|
||||||
>
|
>
|
||||||
{{ t('common.viewText') }}
|
{{ t('common.viewText') }}
|
||||||
|
|
||||||
</a-button>
|
</a-button>
|
||||||
<div v-else class="editable-cell__text-wrapper">
|
<div v-else class="editable-cell__text-wrapper">
|
||||||
{{ `${text.value}` }}
|
{{ `${text.value}` }}
|
||||||
@@ -1465,17 +1467,19 @@ onMounted(() => {
|
|||||||
"
|
"
|
||||||
>
|
>
|
||||||
<a-tooltip>
|
<a-tooltip>
|
||||||
<template #title>{{t('views.configManage.configParam.post')}}</template>
|
<template #title>{{
|
||||||
|
t('views.configManage.configParam.post')
|
||||||
|
}}</template>
|
||||||
<a-popconfirm
|
<a-popconfirm
|
||||||
v-if="
|
v-if="
|
||||||
tableState.arrayChildNewIndex ===
|
tableState.arrayChildNewIndex ===
|
||||||
text[column.key]?.value
|
text[column.key]?.value
|
||||||
"
|
"
|
||||||
:title="
|
:title="
|
||||||
t('views.configManage.configParam.addSure', {
|
t('views.configManage.configParam.addSure', {
|
||||||
value: text[column.key]?.value,
|
value: text[column.key]?.value,
|
||||||
})
|
})
|
||||||
"
|
"
|
||||||
placement="left"
|
placement="left"
|
||||||
@confirm="arrayChildAddOk()"
|
@confirm="arrayChildAddOk()"
|
||||||
>
|
>
|
||||||
@@ -1484,10 +1488,10 @@ onMounted(() => {
|
|||||||
<a-popconfirm
|
<a-popconfirm
|
||||||
v-else
|
v-else
|
||||||
:title="
|
:title="
|
||||||
t('views.configManage.configParam.arraryEdit', {
|
t('views.configManage.configParam.arraryEdit', {
|
||||||
value: text[column.key]?.value,
|
value: text[column.key]?.value,
|
||||||
})
|
})
|
||||||
"
|
"
|
||||||
placement="left"
|
placement="left"
|
||||||
@confirm="arrayChildEditOk()"
|
@confirm="arrayChildEditOk()"
|
||||||
>
|
>
|
||||||
@@ -1609,7 +1613,7 @@ onMounted(() => {
|
|||||||
"
|
"
|
||||||
v-else-if="Array.isArray(text.array)"
|
v-else-if="Array.isArray(text.array)"
|
||||||
>
|
>
|
||||||
{{ t('common.viewText') }}
|
{{ t('common.viewText') }}
|
||||||
</a-button>
|
</a-button>
|
||||||
<div v-else class="editable-cell__text-wrapper">
|
<div v-else class="editable-cell__text-wrapper">
|
||||||
{{ `${text.value}` }}
|
{{ `${text.value}` }}
|
||||||
|
|||||||
@@ -297,9 +297,12 @@ onMounted(() => {
|
|||||||
);
|
);
|
||||||
// 默认选择AMF
|
// 默认选择AMF
|
||||||
const item = neCascaderOtions.value.find(s => s.value === 'AMF');
|
const item = neCascaderOtions.value.find(s => s.value === 'AMF');
|
||||||
if (item) {
|
if (item && item.children) {
|
||||||
const info = item.children[0];
|
const info = item.children[0];
|
||||||
state.neType = [info.neType, info.neId];
|
state.neType = [info.neType, info.neId];
|
||||||
|
} else {
|
||||||
|
const info = neCascaderOtions.value[0].children[0];
|
||||||
|
state.neType = [info.neType, info.neId];
|
||||||
}
|
}
|
||||||
fnGetList();
|
fnGetList();
|
||||||
}
|
}
|
||||||
|
|||||||
Reference in New Issue
Block a user