From 1b5f1820b97b701f975c8f9f22d497ebe287686c Mon Sep 17 00:00:00 2001 From: detraz Date: Sun, 2 Sep 2018 20:22:25 +0200 Subject: [PATCH] Permet la recherche avec telephone et email des users --- search/views.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/search/views.py b/search/views.py index 93aa1d0e..495a7df7 100644 --- a/search/views.py +++ b/search/views.py @@ -140,7 +140,9 @@ def search_single_word(word, filters, user, ) | Q( room__name__icontains=word ) | Q( - room__name__icontains=word + email__icontains=word + ) | Q( + telephone__icontains=word ) ) & Q(state__in=user_state) if not User.can_view_all(user)[0]: