FIX: update tag-chooser & category-selector action (#24318)
This commit is contained in:
parent
10167ad8ee
commit
36ab7ff2a9
|
@ -94,9 +94,7 @@ export default MultiSelectComponent.extend({
|
|||
|
||||
actions: {
|
||||
onChange(values) {
|
||||
this.attrs.onChange(
|
||||
values.map((v) => Category.findById(v)).filter(Boolean)
|
||||
);
|
||||
this.onChange(values.map((v) => Category.findById(v)).filter(Boolean));
|
||||
return false;
|
||||
},
|
||||
},
|
||||
|
|
|
@ -71,8 +71,8 @@ export default MultiSelectComponent.extend(TagsMixin, {
|
|||
|
||||
actions: {
|
||||
onChange(value, items) {
|
||||
if (this.attrs.onChange) {
|
||||
this.attrs.onChange(value, items);
|
||||
if (this.onChange) {
|
||||
this.onChange(value, items);
|
||||
} else {
|
||||
this.set("tags", value);
|
||||
}
|
||||
|
|
Loading…
Reference in New Issue