Bima Ardhia commited on
Commit
970edc1
·
1 Parent(s): b2ff085
Files changed (1) hide show
  1. api.py +1 -1
api.py CHANGED
@@ -39,7 +39,7 @@ def get_transactions(user_id):
39
  # Hitung grand total harian
40
  def prepare_data(df):
41
  df['transaction_date'] = pd.to_datetime(df['transaction_date'])
42
- df = df.sort_values('transaction_date')
43
 
44
  grand_total = 0
45
  grand_totals = []
 
39
  # Hitung grand total harian
40
  def prepare_data(df):
41
  df['transaction_date'] = pd.to_datetime(df['transaction_date'])
42
+ df = df.sort_values(by=['transaction_date', 'id'])
43
 
44
  grand_total = 0
45
  grand_totals = []