diff --git a/backend/api/viewsets/CreditTrade.py b/backend/api/viewsets/CreditTrade.py index a4276d0e5..c1c4cc5f4 100644 --- a/backend/api/viewsets/CreditTrade.py +++ b/backend/api/viewsets/CreditTrade.py @@ -105,7 +105,7 @@ def list_approved(self, request): .get(status="Approved") credit_trades = CreditTrade.objects.filter( - status_id=status_approved.id) + status_id=status_approved.id).order_by('id') serializer = self.get_serializer(credit_trades, many=True) return Response(serializer.data) @@ -116,7 +116,7 @@ def batch_process(self, request): .get(status="Approved") credit_trades = CreditTrade.objects.filter( - status_id=status_approved.id) + status_id=status_approved.id).order_by('id') CreditTradeService.validate_credits(credit_trades)