diff --git a/src/pages/src/components/field-mapping/FieldMapping.vue b/src/pages/src/components/field-mapping/FieldMapping.vue index 149b09341..38fead780 100644 --- a/src/pages/src/components/field-mapping/FieldMapping.vue +++ b/src/pages/src/components/field-mapping/FieldMapping.vue @@ -81,9 +81,9 @@ v-for="option in apiFields" :key="option.key" :id="option.key" - :name="option.key" + :name="formatOptionName(option)" :disabled="option.disabled"> - {{option.key}} + {{ formatOptionName(option) }} @@ -134,6 +134,8 @@ const customConditions = ref([ { name: t('直接'), key: 'direct' }, { name: t('表达式'), key: 'expression' }, ]); + +const formatOptionName = (option: any) => (option.display_name ? `${option.display_name}(${option.key})` : option.key);