mirror of
https://github.com/inventree/InvenTree
synced 2024-08-30 18:33:04 +00:00
Fix filter logic for 'starred' parts
This commit is contained in:
parent
8ac23c080f
commit
134a688e4a
@ -363,9 +363,10 @@ class PartList(generics.ListCreateAPIView):
|
||||
queryset = super().filter_queryset(queryset)
|
||||
|
||||
# Filter by 'starred' parts?
|
||||
starred = str2bool(self.request.query_params.get('starred', None))
|
||||
starred = self.request.query_params.get('starred', None)
|
||||
|
||||
if starred is not None:
|
||||
starred = str2bool(starred)
|
||||
starred_parts = [star.part.pk for star in self.request.user.starred_parts.all()]
|
||||
|
||||
if starred:
|
||||
|
Loading…
Reference in New Issue
Block a user