1
0
Fork 0
mirror of https://github.com/documize/community.git synced 2025-07-23 15:19:42 +02:00

list group members & non-members

This commit is contained in:
sauls8t 2018-02-28 14:55:36 +00:00
parent 19b4a3de49
commit 0680a72ee2
15 changed files with 360 additions and 60 deletions

View file

@ -145,5 +145,24 @@ export default Service.extend({
method: "POST",
data: password
});
}
},
// matchUsers on firstname, lastname, email
matchUsers(text) {
return this.get('ajax').request('users/match', {
method: 'POST',
dataType: 'json',
contentType: 'text',
data: text
}).then((response) => {
let data = [];
data = response.map((obj) => {
let data = this.get('store').normalize('user', obj);
return this.get('store').push(data);
});
return data;
});
}
});