add total to PO serializer

This commit is contained in:
Matthias 2022-03-11 00:26:27 +01:00
parent d086f09771
commit e2d301be3f
No known key found for this signature in database
GPG Key ID: F50EF5741D33E076

View File

@ -53,6 +53,7 @@ class AbstractOrderSerializer:
total_price_string = serializers.CharField(source='get_total_price', read_only=True)
class POSerializer(AbstractOrderSerializer, ReferenceIndexingSerializerMixin, InvenTreeModelSerializer):
""" Serializer for a PurchaseOrder object """
def __init__(self, *args, **kwargs):
@ -122,6 +123,8 @@ class AbstractOrderSerializer:
'status_text',
'target_date',
'notes',
'total_price',
'total_price_string',
]
read_only_fields = [