mirror of
https://gitlab.com/Chill-Projet/chill-bundles.git
synced 2025-06-07 18:44:08 +00:00
filter users which are disabled
This commit is contained in:
parent
26a4577420
commit
572c602387
@ -49,11 +49,12 @@ class SearchUserApiProvider implements SearchApiInterface
|
||||
SIMILARITY(LOWER(UNACCENT(?)), u.usernamecanonical))', [$pattern, $pattern])
|
||||
->setFromClause('users AS u')
|
||||
->setWhereClauses('
|
||||
u.enabled IS TRUE and (
|
||||
SIMILARITY(LOWER(UNACCENT(?)), u.usernamecanonical) > 0.15
|
||||
OR u.usernamecanonical LIKE \'%\' || LOWER(UNACCENT(?)) || \'%\'
|
||||
OR SIMILARITY(LOWER(UNACCENT(?)), LOWER(UNACCENT(u.label))) > 0.15
|
||||
OR u.label LIKE \'%\' || LOWER(UNACCENT(?)) || \'%\'
|
||||
', [$pattern, $pattern, $pattern, $pattern]);
|
||||
)', [$pattern, $pattern, $pattern, $pattern]);
|
||||
|
||||
return $query;
|
||||
}
|
||||
|
Loading…
x
Reference in New Issue
Block a user