mirror of
https://github.com/wekan/wekan.git
synced 2025-12-16 23:40:13 +01:00
Try to fix EasySearch. Part 3.
Thanks to danielkaiser and xet7 !
This commit is contained in:
parent
8fc23429a0
commit
0d3b7ca041
1 changed files with 11 additions and 3 deletions
|
|
@ -539,9 +539,17 @@ Users.allow({
|
|||
// is used for instance to add a new user to a board.
|
||||
UserSearchIndex = new Index({
|
||||
collection: Users,
|
||||
fields: ['username', 'profile.fullname', 'emails.address'],
|
||||
allowedFields: ['username', 'profile.fullname', 'emails.address'],
|
||||
engine: new MongoDBEngine(),
|
||||
fields: ['username', 'profile.fullname', 'profile.avatarUrl'],
|
||||
allowedFields: ['username', 'profile.fullname', 'profile.avatarUrl'],
|
||||
engine: new MongoDBEngine({
|
||||
fields: function(searchObject, options) {
|
||||
return {
|
||||
'username': 1,
|
||||
'profile.fullname': 1,
|
||||
'profile.avatarUrl': 1
|
||||
};
|
||||
}
|
||||
}),
|
||||
});
|
||||
|
||||
Users.safeFields = {
|
||||
|
|
|
|||
Loading…
Add table
Add a link
Reference in a new issue