rairo commited on
Commit
265e96f
·
verified ·
1 Parent(s): 47d3cb5

Update main.py

Browse files
Files changed (1) hide show
  1. main.py +3 -3
main.py CHANGED
@@ -351,13 +351,13 @@ def financial_statement():
351
  cached = doc_ref.get()
352
  if cached.exists:
353
  return jsonify({"report": cached.to_dict()["report"], "cached": True}), 200
354
- datetime.strptime(dt_end), "%d/%m/%Y")
355
  # fetch transactions
356
  snaps = (
357
  fs.collection("transactions")
358
  .where("business_id", "==", biz)
359
- .where("Date", ">=", datetime.strptime(dt_start), "%d/%m/%Y"))
360
- .where("Date", "<=", datetime.strptime(dt_end), "%d/%m/%Y")
361
  .stream()
362
  )
363
  txns = []
 
351
  cached = doc_ref.get()
352
  if cached.exists:
353
  return jsonify({"report": cached.to_dict()["report"], "cached": True}), 200
354
+
355
  # fetch transactions
356
  snaps = (
357
  fs.collection("transactions")
358
  .where("business_id", "==", biz)
359
+ .where("Date", ">=", datetime.strptime(dt_start, "%d/%m/%Y"))
360
+ .where("Date", "<=", datetime.strptime(dt_end, "%d/%m/%Y"))
361
  .stream()
362
  )
363
  txns = []