Merge branch 'master' of github.com:webnotes/erpnext

This commit is contained in:
Anand Doshi 2013-09-05 15:44:59 +05:30
commit 284275cb70

View File

@ -19,7 +19,7 @@ class DocType:
webnotes.conn.get_value("Account", self.doc.account, "debit_or_credit").lower() or "" webnotes.conn.get_value("Account", self.doc.account, "debit_or_credit").lower() or ""
def get_voucher_details(self): def get_voucher_details(self):
total_amount = webnotes.conn.sql("""select %s from `tabGL Entry` total_amount = webnotes.conn.sql("""select sum(%s) from `tabGL Entry`
where voucher_type = %s and voucher_no = %s where voucher_type = %s and voucher_no = %s
and account = %s and ifnull(is_cancelled, 'No') = 'No'""" % and account = %s and ifnull(is_cancelled, 'No') = 'No'""" %
(self.doc.account_type, '%s', '%s', '%s'), (self.doc.account_type, '%s', '%s', '%s'),