Refactor
parent
c733ce6b3b
commit
9985574290
|
@ -709,7 +709,7 @@ export default {
|
|||
return this.isValidOption(option) && this.getOptionLabel(option).toLocaleLowerCase(this.searchLocale) === value.toLocaleLowerCase(this.searchLocale);
|
||||
},
|
||||
isValidOption(option) {
|
||||
return option && !(this.isOptionDisabled(option) || option.optionGroup);
|
||||
return option && !(this.isOptionDisabled(option) || this.isOptionGroup(option));
|
||||
},
|
||||
isSelected(option) {
|
||||
return ObjectUtils.equals(this.modelValue, this.getOptionValue(option), this.equalityKey);
|
||||
|
|
|
@ -668,7 +668,7 @@ export default {
|
|||
return this.isValidOption(option) && this.getOptionLabel(option).toLocaleLowerCase(this.filterLocale).startsWith(this.searchValue.toLocaleLowerCase(this.filterLocale));
|
||||
},
|
||||
isValidOption(option) {
|
||||
return option && !(this.isOptionDisabled(option) || option.optionGroup);
|
||||
return option && !(this.isOptionDisabled(option) || this.isOptionGroup(option));
|
||||
},
|
||||
isValidSelectedOption(option) {
|
||||
return this.isValidOption(option) && this.isSelected(option);
|
||||
|
|
|
@ -493,7 +493,7 @@ export default {
|
|||
return this.isValidOption(option) && this.getOptionLabel(option).toLocaleLowerCase(this.filterLocale).startsWith(this.searchValue.toLocaleLowerCase(this.filterLocale));
|
||||
},
|
||||
isValidOption(option) {
|
||||
return option && !(this.isOptionDisabled(option) || option.optionGroup);
|
||||
return option && !(this.isOptionDisabled(option) || this.isOptionGroup(option));
|
||||
},
|
||||
isValidSelectedOption(option) {
|
||||
return this.isValidOption(option) && this.isSelected(option);
|
||||
|
|
|
@ -783,7 +783,7 @@ export default {
|
|||
return this.isValidOption(option) && this.getOptionLabel(option).toLocaleLowerCase(this.filterLocale).startsWith(this.searchValue.toLocaleLowerCase(this.filterLocale));
|
||||
},
|
||||
isValidOption(option) {
|
||||
return option && !(this.isOptionDisabled(option) || option.optionGroup);
|
||||
return option && !(this.isOptionDisabled(option) || this.isOptionGroup(option));
|
||||
},
|
||||
isValidSelectedOption(option) {
|
||||
return this.isValidOption(option) && this.isSelected(option);
|
||||
|
|
Loading…
Reference in New Issue