mirror of
https://github.com/frappe/erpnext.git
synced 2026-03-19 10:14:59 +00:00
fix: ignore dimension validation for cancelled entries
(cherry picked from commit 971c867f29)
This commit is contained in:
@@ -179,6 +179,7 @@ class GLEntry(Document):
|
|||||||
and self.company == dimension.company
|
and self.company == dimension.company
|
||||||
and dimension.mandatory_for_pl
|
and dimension.mandatory_for_pl
|
||||||
and not dimension.disabled
|
and not dimension.disabled
|
||||||
|
and not self.is_cancelled
|
||||||
):
|
):
|
||||||
if not self.get(dimension.fieldname):
|
if not self.get(dimension.fieldname):
|
||||||
frappe.throw(
|
frappe.throw(
|
||||||
@@ -192,6 +193,7 @@ class GLEntry(Document):
|
|||||||
and self.company == dimension.company
|
and self.company == dimension.company
|
||||||
and dimension.mandatory_for_bs
|
and dimension.mandatory_for_bs
|
||||||
and not dimension.disabled
|
and not dimension.disabled
|
||||||
|
and not self.is_cancelled
|
||||||
):
|
):
|
||||||
if not self.get(dimension.fieldname):
|
if not self.get(dimension.fieldname):
|
||||||
frappe.throw(
|
frappe.throw(
|
||||||
|
|||||||
Reference in New Issue
Block a user