From dc30890b790c6fb7b8a6200d754258252c8ec595 Mon Sep 17 00:00:00 2001 From: Anand Doshi Date: Mon, 2 Sep 2013 17:03:38 +0530 Subject: [PATCH] [fix] [minor] recreate gl entries when using auto inventory accounting to fix bug introduced due to commit - 5dd6b1d082d180133813c1c661d5e72076a19491 --- patches/september_2013/p01_fix_buying_amount_gl_entries.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/patches/september_2013/p01_fix_buying_amount_gl_entries.py b/patches/september_2013/p01_fix_buying_amount_gl_entries.py index 0a25cd4faf..011180a58a 100644 --- a/patches/september_2013/p01_fix_buying_amount_gl_entries.py +++ b/patches/september_2013/p01_fix_buying_amount_gl_entries.py @@ -32,7 +32,7 @@ def recreate_gl_entries(doctype, name, parentfield): from `tab%s` child where docstatus=1 and item_code=%s and ifnull(expense_account, '')!='' and ifnull(cost_center, '')!='' and (select company from `tabAccount` ac where ac.name=child.expense_account)=%s and - (select company from `tabCost Center` cc where cc.name=child.cost_center)=%s and + (select company from `tabCost Center` cc where cc.name=child.cost_center)=%s order by creation desc limit 1""" % (item.doctype, "%s", "%s", "%s"), (item.item_code, bean.doc.company, bean.doc.company)) if res: