mirror of
https://github.com/frappe/erpnext.git
synced 2026-05-26 16:34:46 +00:00
fix: check if shipping rule value exists
(cherry picked from commit af1fce0419)
This commit is contained in:
@@ -258,7 +258,7 @@ class calculate_taxes_and_totals(object):
|
|||||||
|
|
||||||
self.doc.round_floats_in(self.doc, ["total", "base_total", "net_total", "base_net_total"])
|
self.doc.round_floats_in(self.doc, ["total", "base_total", "net_total", "base_net_total"])
|
||||||
|
|
||||||
if hasattr(self.doc, "shipping_rule"):
|
if hasattr(self.doc, "shipping_rule") and self.doc.shipping_rule:
|
||||||
shipping_rule = frappe.get_doc("Shipping Rule", self.doc.shipping_rule)
|
shipping_rule = frappe.get_doc("Shipping Rule", self.doc.shipping_rule)
|
||||||
shipping_rule.apply(self.doc)
|
shipping_rule.apply(self.doc)
|
||||||
|
|
||||||
|
|||||||
Reference in New Issue
Block a user