Skip to content

Commit

Permalink
Merge pull request #1506 from lumi-tip/development-lumi-7920
Browse files Browse the repository at this point in the history
adding visibility filter
  • Loading branch information
tommygonzaleza authored Nov 26, 2024
2 parents 1a66c8e + a1e20a7 commit 1f5dfba
Showing 1 changed file with 4 additions and 0 deletions.
4 changes: 4 additions & 0 deletions breathecode/registry/views.py
Original file line number Diff line number Diff line change
Expand Up @@ -218,6 +218,10 @@ def get(self, request, tech_slug=None):
if like and like not in ["undefined", ""]:
items = items.filter(Q(slug__icontains=like) | Q(title__icontains=like))

if "visibility" in request.GET:
visibility_param = request.GET.get("visibility")
items = items.filter(visibility__iexact=visibility_param)

items = handler.queryset(items)

serializer = AssetTechnologySerializer(items, many=True)
Expand Down

0 comments on commit 1f5dfba

Please sign in to comment.