[fix] [minor] set customer/supplier defaults

This commit is contained in:
Anand Doshi
2013-07-25 17:46:02 +05:30
parent c9c00c904f
commit f2045fb92e
4 changed files with 26 additions and 14 deletions

View File

@@ -89,11 +89,11 @@ class DocType(BuyingController):
return ret
def set_supplier_defaults(self):
self.doc.fields.update(self.get_cust())
self.doc.fields.update(self.get_supplier())
self.doc.fields.update(self.get_credit_to())
super(DocType, self).set_supplier_defaults()
def get_cust(self):
def get_supplier(self):
ret = {}
if self.doc.credit_to:
acc = webnotes.conn.get_value('Account',self.doc.credit_to,['master_name', 'credit_days'])