mirror of
https://github.com/frappe/erpnext.git
synced 2026-02-16 16:15:02 +00:00
expected delivery date mandatory only if order type is sales
This commit is contained in:
@@ -286,7 +286,7 @@ class DocType(TransactionBase):
|
||||
#-----------------------------------------------------------------------------------------------
|
||||
def validate_order_type(self):
|
||||
#validate delivery date
|
||||
if self.doc.order_type != 'Maintenance' and not self.doc.delivery_date:
|
||||
if self.doc.order_type == 'Sales' and not self.doc.delivery_date:
|
||||
msgprint("Please enter 'Expected Delivery Date'")
|
||||
raise Exception
|
||||
|
||||
|
||||
Reference in New Issue
Block a user