Minor improvements to the assigned-to-filter connector
This commit is contained in:
parent
2f2cbd1e11
commit
c4f878a70c
|
@ -4,10 +4,12 @@ export default {
|
||||||
},
|
},
|
||||||
|
|
||||||
setupComponent(args, component) {
|
setupComponent(args, component) {
|
||||||
const groupIDs = component.siteSettings.assign_allowed_on_groups.split("|");
|
const groupIDs = component.siteSettings.assign_allowed_on_groups
|
||||||
|
.split("|")
|
||||||
|
.filter(Boolean);
|
||||||
const groupNames = this.site.groups
|
const groupNames = this.site.groups
|
||||||
.filter(group => groupIDs.includes(group.id.toString()))
|
.filter(group => groupIDs.includes(group.id.toString()))
|
||||||
.map(group => group.name);
|
.mapBy("name");
|
||||||
component.set("allowedGroups", groupNames);
|
component.set("allowedGroups", groupNames);
|
||||||
}
|
}
|
||||||
};
|
};
|
||||||
|
|
Loading…
Reference in New Issue