Fix search?

This commit is contained in:
Robin Champenois 2021-06-28 22:23:00 +02:00
parent 22b5016687
commit 370447d355

View file

@ -136,11 +136,12 @@ def cherche(**kwargs):
# Application # Application
resultat = Stage.objects
if USE_ELASTICSEARCH and use_dsl: if USE_ELASTICSEARCH and use_dsl:
filtres &= Q(id__in=[s.meta.id for s in dsl.scan()]) resultat = dsl.to_queryset(True)
#print(filtres) #print(filtres)
resultat = Stage.objects.filter(filtres) resultat = resultat.filter(filtres).distinct()
tri = 'pertinence' tri = 'pertinence'
if not use_dsl: if not use_dsl: