Merge pull request #23569 from marination/prod-order-reference-in-item

fix: Remove Production Order reference from Item Validation
This commit is contained in:
rohitwaghchaure 2020-10-10 11:03:26 +05:30 committed by GitHub
commit ea8ea4abb5
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -984,9 +984,7 @@ class Item(WebsiteGenerator):
if self.stock_ledger_created():
return True
elif frappe.db.get_value(doctype, filters={"item_code": self.name, "docstatus": 1}) or \
frappe.db.get_value("Production Order",
filters={"production_item": self.name, "docstatus": 1}):
elif frappe.db.get_value(doctype, filters={"item_code": self.name, "docstatus": 1}):
return True
def validate_auto_reorder_enabled_in_stock_settings(self):