【fix-bug78437】选项内容增加搜索条件
This commit is contained in:
@@ -73,6 +73,7 @@
|
||||
dictCode="field_show_type"
|
||||
:placeholder="$t('pleaseSelect') + $t('system.tag.attributeType')"
|
||||
:disabled="disabledEdit"
|
||||
show-search
|
||||
@change="fieldShowTypeChange"
|
||||
/>
|
||||
<!-- @change="form.dictId = undefined"-->
|
||||
@@ -83,7 +84,14 @@
|
||||
<a-col :span="24" v-if="isTagContent">
|
||||
<a-form-model-item :label="$t('system.tag.optionContent')" prop="dictId" key="dictId">
|
||||
<template>
|
||||
<a-select :placeholder="$t('pleaseSelect') + $t('system.tag.optionContent')" v-model="form.dictId" @change="optionContentChange">
|
||||
<a-select
|
||||
:placeholder="$t('pleaseSelect') + $t('system.tag.optionContent')"
|
||||
v-model="form.dictId"
|
||||
@change="optionContentChange"
|
||||
show-search
|
||||
:filter-option="filterOption"
|
||||
>
|
||||
<!-- :filter-option="filterOption"-->
|
||||
<a-select-option v-for="item in contentOption" :key="item.id" :value="item.id">
|
||||
{{ item.dictName }}
|
||||
</a-select-option>
|
||||
@@ -330,6 +338,11 @@ export default {
|
||||
}
|
||||
},
|
||||
methods: {
|
||||
filterOption (input, option) {
|
||||
return (
|
||||
option.componentOptions.children[0].text.toLowerCase().indexOf(input.toLowerCase()) >= 0
|
||||
)
|
||||
},
|
||||
translate (key) {
|
||||
return this.$t(key)
|
||||
},
|
||||
|
||||
Reference in New Issue
Block a user