From 20ce1a297ef890f471c4c9b311d0d0c23ca9eac5 Mon Sep 17 00:00:00 2001 From: tanshu Date: Sat, 11 Sep 2021 13:25:05 +0530 Subject: [PATCH] Fix: Batch autocomplete was not working so Issue / Return was not working --- brewman/brewman/routers/batch.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/brewman/brewman/routers/batch.py b/brewman/brewman/routers/batch.py index eebda48e..3cc2599f 100644 --- a/brewman/brewman/routers/batch.py +++ b/brewman/brewman/routers/batch.py @@ -21,7 +21,7 @@ def batch_term( date = None if not d else datetime.datetime.strptime(d, "%d-%b-%Y") list_ = [] with SessionFuture() as db: - for index, item in enumerate(Batch.list(q, include_nil=False, date=date, db=db)): + for index, item in enumerate(Batch.list(q, include_nil=False, date_=date, db=db)): text = ( f"{item.product.name} ({item.product.units}) {item.quantity_remaining:.2f}@" f"{item.rate:.2f} from {item.name.strftime('%d-%b-%Y')}"