Skip to content

Commit

Permalink
fix max ticket sales api for student tickets
Browse files Browse the repository at this point in the history
  • Loading branch information
Suryansh5545 committed Sep 5, 2023
1 parent 276a63c commit a4a73c5
Showing 1 changed file with 1 addition and 1 deletion.
2 changes: 1 addition & 1 deletion apps/event/views.py
Original file line number Diff line number Diff line change
Expand Up @@ -87,7 +87,7 @@ class get_max_ticket_sales(APIView):
authentication_classes = [authentication.SessionAuthentication]
def get(self, request, pk):
event = Event.objects.get(pk=pk)
tickets = Ticket.objects.filter(event=event, is_active=True)
tickets = Ticket.objects.filter(event=event, is_active=True, ticket_type='REGULAR')
total_amount = 0
for ticket in tickets:
total_amount += ticket.transaction_id.payment_amount
Expand Down

0 comments on commit a4a73c5

Please sign in to comment.