Skip to content
This repository was archived by the owner on May 14, 2024. It is now read-only.
Merged
Changes from all commits
Commits
File filter

Filter by extension

Filter by extension

Conversations
Failed to load comments.
Loading
Jump to
Jump to file
Failed to load files.
Loading
Diff view
Diff view
7 changes: 7 additions & 0 deletions blockstore/apps/rest_api/v1/views/bundles.py
Original file line number Diff line number Diff line change
Expand Up @@ -20,6 +20,13 @@ class BundleFilter(FilterSet):
"""
Filter for BundleViewSet.
"""
def __init__(self, data=None, queryset=None, *, request=None, prefix=None):
# There could be a lot of bundles, so we can't use query params because it will
# raise the "Request-URI Too Long" error. Use the request data in such case.
# NOTE: query_params (data arg) have a higher priority than the request.data
data = data or request.data or {}
super().__init__(data, queryset, request=request, prefix=prefix)

uuid = AllValuesMultipleFilter(widget=CSVWidget) # Accepts multiple comma-separated UUIDs
text_search = CharFilter(method='search')

Expand Down