mirror of
https://github.com/inventree/InvenTree.git
synced 2025-04-29 20:16:44 +00:00
Style fixes
This commit is contained in:
parent
15d27cafec
commit
f21a05dfa3
@ -184,7 +184,7 @@ def FilterChildren(queryset, parent):
|
|||||||
|
|
||||||
if not parent:
|
if not parent:
|
||||||
return queryset
|
return queryset
|
||||||
elif isinstance(parent,str) and parent.lower() in ['none', 'false', 'null', 'top', '0']:
|
elif isinstance(parent, str) and parent.lower() in ['none', 'false', 'null', 'top', '0']:
|
||||||
return queryset.filter(parent=None)
|
return queryset.filter(parent=None)
|
||||||
else:
|
else:
|
||||||
try:
|
try:
|
||||||
|
@ -29,7 +29,7 @@ projectcategorypatterns = [
|
|||||||
|
|
||||||
urlpatterns = [
|
urlpatterns = [
|
||||||
# Individual project URL
|
# Individual project URL
|
||||||
url(r'^(?P<pk>[0-9]+)/?$', include(projectdetailpatterns)),
|
url(r'^(?P<pk>[0-9]+)/?', include(projectdetailpatterns)),
|
||||||
|
|
||||||
# List of all projects
|
# List of all projects
|
||||||
url(r'^$', views.ProjectList.as_view()),
|
url(r'^$', views.ProjectList.as_view()),
|
||||||
|
@ -21,6 +21,7 @@ class StockFilter(django_filters.rest_framework.FilterSet):
|
|||||||
model = StockItem
|
model = StockItem
|
||||||
fields = ['quantity']
|
fields = ['quantity']
|
||||||
|
|
||||||
|
|
||||||
class StockList(generics.ListCreateAPIView):
|
class StockList(generics.ListCreateAPIView):
|
||||||
|
|
||||||
serializer_class = StockItemSerializer
|
serializer_class = StockItemSerializer
|
||||||
|
Loading…
x
Reference in New Issue
Block a user