Credit Note print format

This commit is contained in:
Nabin Hait
2015-07-22 17:47:49 +05:30
parent b74999da82
commit 04d244a360
7 changed files with 45 additions and 24 deletions

View File

@@ -173,6 +173,9 @@ class AccountsController(TransactionBase):
def validate_due_date(self):
from erpnext.accounts.party import validate_due_date
if self.doctype == "Sales Invoice":
if not self.due_date:
frappe.throw(_("Due Date is mandatory"))
validate_due_date(self.posting_date, self.due_date, "Customer", self.customer, self.company)
elif self.doctype == "Purchase Invoice":
validate_due_date(self.posting_date, self.due_date, "Supplier", self.supplier, self.company)