Merge branch 'develop' into item-attr-abbr-lowercase

This commit is contained in:
Sagar Sharma 2023-01-15 12:55:01 +05:30 committed by GitHub
commit bfbc9ea8f7
No known key found for this signature in database
GPG Key ID: 4AEE18F83AFDEB23

View File

@ -63,6 +63,11 @@ class SubcontractingReceipt(SubcontractingController):
self.set_items_expense_account()
def validate(self):
if (
frappe.db.get_single_value("Buying Settings", "backflush_raw_materials_of_subcontract_based_on")
== "BOM"
):
self.supplied_items = []
super(SubcontractingReceipt, self).validate()
self.set_missing_values()
self.validate_posting_time()