fix
This commit is contained in:
@@ -347,7 +347,6 @@ class CounterpartyAKTApiView(views.APIView):
|
||||
return Response(response, status=200)
|
||||
|
||||
def _group_by_date(self, parties, expences, incomes):
|
||||
"""Kun boyicha guruhlash"""
|
||||
daily_data = defaultdict(lambda: {
|
||||
'parties': [],
|
||||
'expences': [],
|
||||
@@ -360,7 +359,7 @@ class CounterpartyAKTApiView(views.APIView):
|
||||
})
|
||||
|
||||
for party in parties:
|
||||
date_key = party.close_date.strftime('%Y-%m-%d')
|
||||
date_key = party.closed_date.strftime('%Y-%m-%d')
|
||||
daily_data[date_key]['parties'].append(party)
|
||||
|
||||
party_total = getattr(party, 'total_price', 0) or 0
|
||||
|
||||
Reference in New Issue
Block a user