mirror of
https://github.com/frappe/erpnext.git
synced 2026-03-25 14:11:45 +01:00
fix: redundant message on bom save
(cherry picked from commit 074f07694f)
# Conflicts:
# erpnext/manufacturing/doctype/bom/bom.py
This commit is contained in:
@@ -465,7 +465,7 @@ class BOM(WebsiteGenerator):
|
|||||||
)
|
)
|
||||||
)
|
)
|
||||||
|
|
||||||
def get_rm_rate(self, arg):
|
def get_rm_rate(self, arg, notify=True):
|
||||||
"""Get raw material rate as per selected method, if bom exists takes bom cost"""
|
"""Get raw material rate as per selected method, if bom exists takes bom cost"""
|
||||||
rate = 0
|
rate = 0
|
||||||
if not self.rm_cost_as_per:
|
if not self.rm_cost_as_per:
|
||||||
@@ -491,7 +491,7 @@ class BOM(WebsiteGenerator):
|
|||||||
),
|
),
|
||||||
alert=True,
|
alert=True,
|
||||||
)
|
)
|
||||||
else:
|
elif notify:
|
||||||
frappe.msgprint(
|
frappe.msgprint(
|
||||||
_("{0} not found for item {1}").format(self.rm_cost_as_per, arg["item_code"]),
|
_("{0} not found for item {1}").format(self.rm_cost_as_per, arg["item_code"]),
|
||||||
alert=True,
|
alert=True,
|
||||||
@@ -796,7 +796,13 @@ class BOM(WebsiteGenerator):
|
|||||||
"stock_uom": d.stock_uom,
|
"stock_uom": d.stock_uom,
|
||||||
"conversion_factor": d.conversion_factor,
|
"conversion_factor": d.conversion_factor,
|
||||||
"sourced_by_supplier": d.sourced_by_supplier,
|
"sourced_by_supplier": d.sourced_by_supplier,
|
||||||
|
<<<<<<< HEAD
|
||||||
}
|
}
|
||||||
|
=======
|
||||||
|
"is_phantom_item": d.is_phantom_item,
|
||||||
|
},
|
||||||
|
notify=False,
|
||||||
|
>>>>>>> 074f07694f (fix: redundant message on bom save)
|
||||||
)
|
)
|
||||||
|
|
||||||
d.base_rate = flt(d.rate) * flt(self.conversion_rate)
|
d.base_rate = flt(d.rate) * flt(self.conversion_rate)
|
||||||
|
|||||||
Reference in New Issue
Block a user