mirror of https://github.com/ElemeFE/element
减少嵌套
parent
cadcd91968
commit
cbf3a9e1f6
|
@ -73,12 +73,10 @@
|
|||
select(item, menuIndex) {
|
||||
if (item.__IS__FLAT__OPTIONS) {
|
||||
this.activeValue = item.value;
|
||||
} else if (menuIndex) {
|
||||
this.activeValue.splice(menuIndex, this.activeValue.length - 1, item.value);
|
||||
} else {
|
||||
if (menuIndex) {
|
||||
this.activeValue.splice(menuIndex, this.activeValue.length - 1, item.value);
|
||||
} else {
|
||||
this.activeValue = [item.value];
|
||||
}
|
||||
this.activeValue = [item.value];
|
||||
}
|
||||
this.$emit('pick', this.activeValue);
|
||||
},
|
||||
|
|
Loading…
Reference in New Issue