diff --git a/erpnext/patches.txt b/erpnext/patches.txt index 35b1bedb1f..5d29096f14 100644 --- a/erpnext/patches.txt +++ b/erpnext/patches.txt @@ -20,4 +20,4 @@ erpnext.patches.4_0.map_charge_to_taxes_and_charges execute:webnotes.reload_doc('support', 'doctype', 'newsletter') # 2014-01-31 execute:webnotes.reload_doc('hr', 'doctype', 'employee') # 2014-02-03 execute:webnotes.conn.sql("update tabPage set module='Core' where name='Setup'") -execute:patches.4_0.fields_to_be_renamed +erpnext.patches.4_0.fields_to_be_renamed diff --git a/erpnext/stock/get_item_details.py b/erpnext/stock/get_item_details.py index 5de856dee3..8bd00b6527 100644 --- a/erpnext/stock/get_item_details.py +++ b/erpnext/stock/get_item_details.py @@ -121,7 +121,7 @@ def get_basic_details(args, item_bean): user_default_warehouse_list = get_user_default_as_list('warehouse') user_default_warehouse = user_default_warehouse_list[0] \ if len(user_default_warehouse_list)==1 else "" - + out = webnotes._dict({ "item_code": item.name, "item_name": item.item_name, @@ -132,7 +132,7 @@ def get_basic_details(args, item_bean): "expense_account": item.expense_account or args.expense_account \ or webnotes.conn.get_value("Company", args.company, "default_expense_account"), "cost_center": item.selling_cost_center \ - if args.transaction_type == "selling" else args.buying_cost_center, + if args.transaction_type == "selling" else item.buying_cost_center, "batch_no": None, "item_tax_rate": json.dumps(dict(([d.tax_type, d.tax_rate] for d in item_bean.doclist.get({"parentfield": "item_tax"})))),