File tree 1 file changed +5
-5
lines changed 1 file changed +5
-5
lines changed Original file line number Diff line number Diff line change 10
10
from django .views .generic .list import ListView
11
11
from django .views .generic import TemplateView , View
12
12
from django .urls import reverse
13
- from elasticsearch_dsl import Q
13
+ from elasticsearch_dsl import Q as elasticQ
14
14
15
15
from app .documents import TenderDoc , TenderDocumentDoc , WinnerDoc
16
16
from app .forms import TendersFilter
@@ -256,7 +256,7 @@ def get_context_data(self, **kwargs):
256
256
257
257
# Find the tenders that have documents containing the input string
258
258
result_tender_documents = TenderDocumentDoc .search ().query (
259
- Q (
259
+ elasticQ (
260
260
"multi_match" ,
261
261
query = pk ,
262
262
fields = [
@@ -269,7 +269,7 @@ def get_context_data(self, **kwargs):
269
269
270
270
# Find the tenders that match the input string and the tender ids of the tender documents
271
271
result_tenders = TenderDoc .search ().query (
272
- Q (
272
+ elasticQ (
273
273
"multi_match" ,
274
274
query = pk ,
275
275
fields = [
@@ -283,14 +283,14 @@ def get_context_data(self, **kwargs):
283
283
]
284
284
)
285
285
|
286
- Q (
286
+ elasticQ (
287
287
"terms" ,
288
288
reference = tender_references ,
289
289
)
290
290
)
291
291
292
292
result_awards = WinnerDoc .search ().query (
293
- Q (
293
+ elasticQ (
294
294
"multi_match" ,
295
295
query = pk ,
296
296
fields = [
You can’t perform that action at this time.
0 commit comments