From 0b6e59076691f1850ae485cc44feebf3e50b79de Mon Sep 17 00:00:00 2001 From: Nabin Hait Date: Fri, 2 Aug 2013 16:08:04 +0530 Subject: [PATCH] [fix] [minor] get supplier details in purchase invoice --- accounts/doctype/purchase_invoice/purchase_invoice.py | 10 ---------- 1 file changed, 10 deletions(-) diff --git a/accounts/doctype/purchase_invoice/purchase_invoice.py b/accounts/doctype/purchase_invoice/purchase_invoice.py index 141811d0f9..9e220fd30c 100644 --- a/accounts/doctype/purchase_invoice/purchase_invoice.py +++ b/accounts/doctype/purchase_invoice/purchase_invoice.py @@ -91,19 +91,9 @@ class DocType(BuyingController): return ret def set_supplier_defaults(self): - self.doc.fields.update(self.get_supplier()) self.doc.fields.update(self.get_credit_to()) super(DocType, self).set_supplier_defaults() - def get_supplier(self): - ret = {} - if self.doc.credit_to: - acc = webnotes.conn.get_value('Account',self.doc.credit_to,['master_name', 'credit_days']) - ret['supplier'] = acc[0] - ret['due_date'] = add_days(cstr(self.doc.posting_date), acc and cint(acc[1]) or 0) - - return ret - def get_advances(self): super(DocType, self).get_advances(self.doc.credit_to, "Purchase Invoice Advance", "advance_allocation_details", "debit")