2
0
mirror of https://github.com/inventree/InvenTree.git synced 2025-07-13 08:21:26 +00:00

Allow files to be uploaded alongside a test report

- Attach the file to the stock item
- Link the uploaded attachment to the test report
This commit is contained in:
Oliver Walters
2020-05-16 22:53:23 +10:00
parent 247cfcc514
commit 45556058d2
3 changed files with 77 additions and 3 deletions

View File

@ -212,6 +212,7 @@ class StockItemAttachmentSerializer(InvenTreeModelSerializer):
'stock_item',
'attachment',
'comment',
'date',
'user',
'user_detail',
]
@ -235,6 +236,14 @@ class StockItemTestResultSerializer(InvenTreeModelSerializer):
'date'
]
read_only_fields = [
'pk',
'stock_item',
'attachment',
'user',
'date',
]
class StockTrackingSerializer(InvenTreeModelSerializer):
""" Serializer for StockItemTracking model """