fix: ignore permissions when cancelling revaluation journal entry

(cherry picked from commit 500c44e3f5)
This commit is contained in:
Navin-S-R
2026-01-11 21:30:09 +05:30
committed by Mergify
parent 426516a1ee
commit 129457b2ce

View File

@@ -210,6 +210,8 @@ class AssetValueAdjustment(Document):
revaluation_entry = frappe.get_doc("Journal Entry", self.journal_entry) revaluation_entry = frappe.get_doc("Journal Entry", self.journal_entry)
if revaluation_entry.docstatus == 1: if revaluation_entry.docstatus == 1:
# Ignore permissions to match Journal Entry submission behavior
revaluation_entry.flags.ignore_permissions = True
revaluation_entry.cancel() revaluation_entry.cancel()
def update_asset(self): def update_asset(self):