mirror of
https://github.com/paperless-ngx/paperless-ngx.git
synced 2025-12-11 09:07:18 +01:00
Fix broken date range search
This commit is contained in:
parent
51a5746611
commit
5e9a7b94ba
1 changed files with 10 additions and 8 deletions
|
|
@ -468,6 +468,8 @@ class DocumentViewSet(
|
||||||
class SearchResultSerializer(DocumentSerializer):
|
class SearchResultSerializer(DocumentSerializer):
|
||||||
def to_representation(self, instance):
|
def to_representation(self, instance):
|
||||||
doc = Document.objects.get(id=instance["id"])
|
doc = Document.objects.get(id=instance["id"])
|
||||||
|
comments = ""
|
||||||
|
if hasattr(instance.results.q, "subqueries"):
|
||||||
commentTerm = instance.results.q.subqueries[0]
|
commentTerm = instance.results.q.subqueries[0]
|
||||||
comments = ",".join(
|
comments = ",".join(
|
||||||
[
|
[
|
||||||
|
|
|
||||||
Loading…
Add table
Add a link
Reference in a new issue