mirror of
https://github.com/lemeow125/Ivy-Backend.git
synced 2024-11-17 06:39:26 +08:00
Changed history in products url to reflect quantity and date timestamp
This commit is contained in:
parent
17495c960b
commit
9c8889df0e
1 changed files with 1 additions and 1 deletions
|
@ -7,7 +7,7 @@ class HistoricalRecordField(serializers.ListField):
|
|||
child = serializers.DictField()
|
||||
|
||||
def to_representation(self, data):
|
||||
return super().to_representation(data.values('id', 'history_date').order_by('history_date'))
|
||||
return super().to_representation(data.values('quantity', 'history_date').order_by('history_date'))
|
||||
|
||||
|
||||
class ProductSerializer(serializers.HyperlinkedModelSerializer):
|
||||
|
|
Loading…
Reference in a new issue