select增加清除按钮配置

This commit is contained in:
qinjie 2021-09-10 23:53:56 +08:00
parent a9cf0a4dc0
commit 63fadefa5c
1 changed files with 2 additions and 2 deletions

View File

@ -7,12 +7,12 @@
<a-input v-if="item.type === 'input'" v-model="form[item.key]" :type="item.type || 'text'" :placeholder="item.placeholder || '请输入'" :allowClear="true" />
<!-- select-common -->
<a-select v-if="item.type === 'select'" v-model="form[item.key]" placeholder="请选择">
<a-select v-if="item.type === 'select'" v-model="form[item.key]" placeholder="请选择" :allowClear="true">
<a-select-option v-for="(j, k) in item.options" :key="`${index}-${k}`" :value="j.id">{{ j.name }}</a-select-option>
</a-select>
<!-- select-dictionary -->
<a-select v-if="item.type === 'select-dic'" v-model="form[item.key]" placeholder="请选择">
<a-select v-if="item.type === 'select-dic'" v-model="form[item.key]" placeholder="请选择" :allowClear="true">
<a-select-option v-for="(j, k) in item.options" :key="`${index}-${k}`" :value="j.value">{{ j.name }}</a-select-option>
</a-select>