From 3d969c25fa2c57e16f3ad88649b94457487e49db Mon Sep 17 00:00:00 2001 From: simon Date: Sun, 14 Nov 2021 15:51:55 +0700 Subject: [PATCH] only show playlist if at least one entry --- tubearchivist/home/views.py | 4 +++- 1 file changed, 3 insertions(+), 1 deletion(-) diff --git a/tubearchivist/home/views.py b/tubearchivist/home/views.py index 9ca1f0a..61bdeb9 100644 --- a/tubearchivist/home/views.py +++ b/tubearchivist/home/views.py @@ -719,7 +719,9 @@ class PlaylistView(View): data = { "size": pagination_handler.pagination["page_size"], "from": pagination_handler.pagination["page_from"], - "query": {"match_all": {}}, + "query": { + "term": {"playlist_entries.downloaded": {"value": True}} + }, "sort": [{"playlist_name.keyword": {"order": "asc"}}], } search = SearchHandler(url, data)