mirror of
https://github.com/codeninjasllc/discourse.git
synced 2024-12-11 08:11:15 -05:00
e300945879
FIX: clear the user-selector when adding new members
20 lines
497 B
JavaScript
20 lines
497 B
JavaScript
export default Discourse.Route.extend({
|
|
|
|
model: function(params) {
|
|
var groups = this.modelFor('adminGroupsType'),
|
|
group = groups.findProperty('name', params.name);
|
|
|
|
if (!group) { return this.transitionTo('adminGroups.index'); }
|
|
|
|
return group;
|
|
},
|
|
|
|
setupController: function(controller, model) {
|
|
controller.set("model", model);
|
|
// clear the user selector
|
|
controller.set("usernames", null);
|
|
// load the members of the group
|
|
model.findMembers();
|
|
}
|
|
|
|
});
|