From f6911fb51c4f8efcd6baa3403f0fc58835511400 Mon Sep 17 00:00:00 2001 From: Nabin Hait Date: Wed, 29 May 2013 11:06:17 +0530 Subject: [PATCH] Update sales_invoice.py [fixes] pulling available qty on selection of item in case of pos --- accounts/doctype/sales_invoice/sales_invoice.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/accounts/doctype/sales_invoice/sales_invoice.py b/accounts/doctype/sales_invoice/sales_invoice.py index 6871b1e90f..ab44247d5c 100644 --- a/accounts/doctype/sales_invoice/sales_invoice.py +++ b/accounts/doctype/sales_invoice/sales_invoice.py @@ -351,7 +351,7 @@ class DocType(SellingController): if ret.get("warehouse"): ret["actual_qty"] = flt(webnotes.conn.get_value("Bin", - {"item_code": args.get("item_code"), "warehouse": args.get("warehouse")}, + {"item_code": args.get("item_code"), "warehouse": ret.get("warehouse")}, "actual_qty")) return ret