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])
|
SIMILARITY(LOWER(UNACCENT(?)), u.usernamecanonical))', [$pattern, $pattern])
|
||||||
->setFromClause('users AS u')
|
->setFromClause('users AS u')
|
||||||
->setWhereClauses('
|
->setWhereClauses('
|
||||||
|
u.enabled IS TRUE and (
|
||||||
SIMILARITY(LOWER(UNACCENT(?)), u.usernamecanonical) > 0.15
|
SIMILARITY(LOWER(UNACCENT(?)), u.usernamecanonical) > 0.15
|
||||||
OR u.usernamecanonical LIKE \'%\' || LOWER(UNACCENT(?)) || \'%\'
|
OR u.usernamecanonical LIKE \'%\' || LOWER(UNACCENT(?)) || \'%\'
|
||||||
OR SIMILARITY(LOWER(UNACCENT(?)), LOWER(UNACCENT(u.label))) > 0.15
|
OR SIMILARITY(LOWER(UNACCENT(?)), LOWER(UNACCENT(u.label))) > 0.15
|
||||||
OR u.label LIKE \'%\' || LOWER(UNACCENT(?)) || \'%\'
|
OR u.label LIKE \'%\' || LOWER(UNACCENT(?)) || \'%\'
|
||||||
', [$pattern, $pattern, $pattern, $pattern]);
|
)', [$pattern, $pattern, $pattern, $pattern]);
|
||||||
|
|
||||||
return $query;
|
return $query;
|
||||||
}
|
}
|
||||||
|
Loading…
x
Reference in New Issue
Block a user