Include UID field in StockItem API

This commit is contained in:
Oliver Walters 2020-04-14 22:57:46 +10:00
parent ba4a1fd771
commit 977316cb3a
2 changed files with 4 additions and 1 deletions

View File

@ -344,6 +344,7 @@ class StockList(generics.ListCreateAPIView):
data = queryset.values( data = queryset.values(
'pk', 'pk',
'uid',
'parent', 'parent',
'quantity', 'quantity',
'serial', 'serial',
@ -540,7 +541,7 @@ class StockList(generics.ListCreateAPIView):
'supplier_part', 'supplier_part',
'customer', 'customer',
'belongs_to', 'belongs_to',
'build' 'build',
] ]

View File

@ -39,6 +39,7 @@ class StockItemSerializerBrief(InvenTreeModelSerializer):
model = StockItem model = StockItem
fields = [ fields = [
'pk', 'pk',
'uid',
'part', 'part',
'part_name', 'part_name',
'supplier_part', 'supplier_part',
@ -106,6 +107,7 @@ class StockItemSerializer(InvenTreeModelSerializer):
'status', 'status',
'status_text', 'status_text',
'tracking_items', 'tracking_items',
'uid',
'url', 'url',
] ]