frappe/frappe#478, removed instances of .fields

This commit is contained in:
Rushabh Mehta
2014-03-31 23:37:40 +05:30
parent 231f6a5b58
commit f2227d033c
32 changed files with 61 additions and 63 deletions

View File

@@ -363,11 +363,11 @@ class SellingController(StockController):
def check_stop_sales_order(self, ref_fieldname):
for d in self.get(self.fname):
if d.get(ref_fieldname):
status = frappe.db.get_value("Sales Order", d.fields[ref_fieldname], "status")
status = frappe.db.get_value("Sales Order", d.get(ref_fieldname), "status")
if status == "Stopped":
frappe.throw(self.doctype +
_(" can not be created/modified against stopped Sales Order ") +
d.fields[ref_fieldname])
d.get(ref_fieldname))
def check_active_sales_items(obj):
for d in obj.doclist.get({"parentfield": obj.fname}):