This commit is contained in:
梁灏 2018-12-17 15:37:07 +08:00
parent dcb4839732
commit 2bdeea65ec

View file

@ -632,7 +632,7 @@
this.broadcast('Drop', 'on-update-popper'); this.broadcast('Drop', 'on-update-popper');
setTimeout(() => { setTimeout(() => {
this.filterQueryChange = false; this.filterQueryChange = false;
},300) }, ANIMATION_TIMEOUT);
}, },
onQueryChange(query) { onQueryChange(query) {
if (query.length > 0 && query !== this.query) this.visible = true; if (query.length > 0 && query !== this.query) this.visible = true;
@ -759,6 +759,21 @@
this.$emit('on-open-change', state); this.$emit('on-open-change', state);
}, },
slotOptions(options, old){ slotOptions(options, old){
// #4626 Options label v-model
if (options && options.length && this.values.length) {
this.values = this.values.map(value => {
const option = options.find(option => option.componentOptions.propsData.value === value.value);
if(!option) return null;
const label = getOptionLabel(option);
return {
value: value.value,
label: label
};
}).filter(Boolean);
}
// dropdown // dropdown
// dropdown // dropdown
if (options && old && options.length !== old.length) { if (options && old && options.length !== old.length) {