Skip to content

Commit 7257fcd

Browse files
committed
add thirdparty/sameeboy handling
1 parent aae5aca commit 7257fcd

File tree

1 file changed

+7
-0
lines changed

1 file changed

+7
-0
lines changed

hhub/views.py

+7
Original file line numberDiff line numberDiff line change
@@ -77,6 +77,7 @@ def entries_all(request):
7777
)
7878
return JsonResponse(serializer.data, safe=False)
7979

80+
8081
def search_entries(request):
8182
"""
8283
Returns every entry matching the conditions given in the query
@@ -93,6 +94,7 @@ def search_entries(request):
9394
platform = request.GET.get("platform", "")
9495
text_query = request.GET.get("q", "")
9596
random_query = request.GET.get("random", False)
97+
thirdparty = request.GET.get("thirdparty", "")
9698

9799
# Pagination
98100
# Request a specific page
@@ -113,6 +115,11 @@ def search_entries(request):
113115
# elif num_elements >= 30:
114116
# num_elements = 30
115117

118+
# TODO: Implement filtering on the new schema field for distribution terms
119+
# to third parties. For now, make sameboy return empty
120+
if thirdparty == "sameboy":
121+
entries = []
122+
116123
# sort and order
117124
if sort_by_param:
118125
entries = sort_and_order(entries, order_by_param, sort_by_param)

0 commit comments

Comments
 (0)