From aabe11b689df77a09a37cb785725efde54c5e90c Mon Sep 17 00:00:00 2001 From: Anand Doshi Date: Thu, 23 May 2013 12:59:12 +0530 Subject: [PATCH] [sales order] [validate] validate item details specifically when submitting --- selling/doctype/sales_order/sales_order.py | 5 ++++- 1 file changed, 4 insertions(+), 1 deletion(-) diff --git a/selling/doctype/sales_order/sales_order.py b/selling/doctype/sales_order/sales_order.py index 6a52e5a0fa..c8db1f919f 100644 --- a/selling/doctype/sales_order/sales_order.py +++ b/selling/doctype/sales_order/sales_order.py @@ -217,7 +217,10 @@ class DocType(SellingController): self.validate_proj_cust() self.validate_po() #self.validate_reference_value() - self.validate_for_items() + + if self.doc.docstatus == 1: + self.validate_for_items() + sales_com_obj = get_obj(dt = 'Sales Common') sales_com_obj.check_active_sales_items(self) sales_com_obj.check_conversion_rate(self)