From 63b275c97f74e9590027535e13c1f8a75e75c2bf Mon Sep 17 00:00:00 2001 From: Nabin Hait Date: Thu, 1 Mar 2012 10:35:35 +0530 Subject: [PATCH] allowed debit and credit against same acc head --- erpnext/accounts/doctype/gl_entry/gl_entry.py | 8 +++++--- 1 file changed, 5 insertions(+), 3 deletions(-) diff --git a/erpnext/accounts/doctype/gl_entry/gl_entry.py b/erpnext/accounts/doctype/gl_entry/gl_entry.py index c45e1625ac1..3892007bb4d 100644 --- a/erpnext/accounts/doctype/gl_entry/gl_entry.py +++ b/erpnext/accounts/doctype/gl_entry/gl_entry.py @@ -36,10 +36,12 @@ class DocType: msgprint("GL Entry: Debit or Credit amount is mandatory for %s" % self.doc.account) raise Exception + + # COMMMENTED below to allow zero amount (+ and -) entry in tax table # Debit and credit can not done at the same time - if flt(self.doc.credit) != 0 and flt(self.doc.debit) != 0: - msgprint("Sorry you cannot credit and debit under same account head.") - raise Exception, "Validation Error." + #if flt(self.doc.credit) != 0 and flt(self.doc.debit) != 0: + # msgprint("Sorry you cannot credit and debit under same account head.") + # raise Exception, "Validation Error." # Cost center is required only if transaction made against pl account #--------------------------------------------------------------------