mirror of
https://github.com/frappe/erpnext.git
synced 2026-06-03 04:09:11 +00:00
Fixed conflict while merging v4 into v5
This commit is contained in:
@@ -6,11 +6,11 @@ import frappe
|
||||
|
||||
def execute():
|
||||
for d in frappe.db.sql("select name from `tabBOM` where docstatus < 2"):
|
||||
try:
|
||||
try:
|
||||
document = frappe.get_doc('BOM', d[0])
|
||||
if document.docstatus == 1:
|
||||
document.ignore_validate_update_after_submit = True
|
||||
document.flags.ignore_validate_update_after_submit = True
|
||||
document.calculate_cost()
|
||||
document.save()
|
||||
except:
|
||||
pass
|
||||
pass
|
||||
|
||||
@@ -9,7 +9,7 @@ def execute():
|
||||
for d in frappe.db.sql("""select name from `tabBOM` where docstatus < 2""", as_dict=1):
|
||||
try:
|
||||
bom = frappe.get_doc('BOM', d.name)
|
||||
bom.ignore_validate_update_after_submit = True
|
||||
bom.flags.ignore_validate_update_after_submit = True
|
||||
bom.calculate_cost()
|
||||
bom.save()
|
||||
frappe.db.commit()
|
||||
|
||||
Reference in New Issue
Block a user