From f044526b9272bd37ea7fa3fb1a12cdeb8e04903e Mon Sep 17 00:00:00 2001 From: Nabin Hait Date: Tue, 15 May 2012 15:29:47 +0530 Subject: [PATCH] json error fixed in stock entry --- erpnext/stock/doctype/stock_entry/stock_entry.py | 3 ++- 1 file changed, 2 insertions(+), 1 deletion(-) diff --git a/erpnext/stock/doctype/stock_entry/stock_entry.py b/erpnext/stock/doctype/stock_entry/stock_entry.py index dee8790adc..e56ad03942 100644 --- a/erpnext/stock/doctype/stock_entry/stock_entry.py +++ b/erpnext/stock/doctype/stock_entry/stock_entry.py @@ -49,7 +49,8 @@ class DocType(TransactionBase): # get item details # ---------------- def get_item_details(self, arg): - arg, actual_qty, in_rate = eval(arg), 0, 0 + import json + arg, actual_qty, in_rate = json.loads(arg), 0, 0 item = sql("select stock_uom, description, item_name from `tabItem` where name = %s and (ifnull(end_of_life,'')='' or end_of_life ='0000-00-00' or end_of_life > now())", (arg.get('item_code')), as_dict = 1) if not item: