Adjust context size and pass it directly

This commit is contained in:
Mark Veidemanis 2022-09-12 08:23:03 +01:00
parent 8add25ac27
commit 4b99d7272c
Signed by: m
GPG Key ID: 5ACFCEED46C0904F
1 changed files with 3 additions and 2 deletions

View File

@ -289,7 +289,7 @@ class DrilldownContextModal(APIView):
if request.resolver_match.url_name == "modal_context_table":
self.template_name = "partials/context_table.html"
size = 20
size = 15
nicks_sensitive = None
query = False
# Create the query params from the POST arguments
@ -356,6 +356,7 @@ class DrilldownContextModal(APIView):
query_params["sorting"] = "desc"
# SAFE_PARAMS["sorting"] = "desc"
query_params["size"] = size
annotate = False
if query_params["source"] == "irc":
@ -374,10 +375,10 @@ class DrilldownContextModal(APIView):
type=type,
nicks=nicks_sensitive,
)
results = query_results(
request,
query_params,
size=size,
annotate=annotate,
custom_query=search_query,
reverse=True,