mirror of
https://gitlab.crans.org/bde/nk20
synced 2024-12-22 23:42:25 +00:00
Don't match users only with the start of the name
This commit is contained in:
parent
eb3d426947
commit
dd4b24d999
@ -185,9 +185,9 @@ class UserListView(ProtectQuerysetMixin, LoginRequiredMixin, SingleTableView):
|
||||
Q(first_name__iregex=pattern)
|
||||
| Q(last_name__iregex=pattern)
|
||||
| Q(profile__section__iregex=pattern)
|
||||
| Q(username__iregex="^" + pattern)
|
||||
| Q(alias__iregex="^" + pattern)
|
||||
| Q(normalized_alias__iregex=Alias.normalize("^" + pattern))
|
||||
| Q(username__iregex=pattern)
|
||||
| Q(alias__iregex=pattern)
|
||||
| Q(normalized_alias__iregex=Alias.normalize(pattern))
|
||||
)
|
||||
else:
|
||||
qs = qs.none()
|
||||
|
Loading…
Reference in New Issue
Block a user