Merge pull request #21562 from deepeshgarg007/make_reverse_entry
fix: Reverse GL Entry on cancel fix
diff --git a/erpnext/accounts/doctype/period_closing_voucher/period_closing_voucher.py b/erpnext/accounts/doctype/period_closing_voucher/period_closing_voucher.py
index 0bd9a90..bd8d8bd 100644
--- a/erpnext/accounts/doctype/period_closing_voucher/period_closing_voucher.py
+++ b/erpnext/accounts/doctype/period_closing_voucher/period_closing_voucher.py
@@ -19,7 +19,7 @@
def on_cancel(self):
self.ignore_linked_doctypes = ('GL Entry', 'Stock Ledger Entry')
from erpnext.accounts.general_ledger import make_reverse_gl_entries
- make_reverse_gl_entries(voucher_type="Period Closing Voucher", voucher_no=self.name, cancel=True)
+ make_reverse_gl_entries(voucher_type="Period Closing Voucher", voucher_no=self.name)
def validate_account_head(self):
closing_account_type = frappe.db.get_value("Account", self.closing_account_head, "root_type")
diff --git a/erpnext/education/doctype/fees/fees.py b/erpnext/education/doctype/fees/fees.py
index 01f7b87..f0d60fa 100644
--- a/erpnext/education/doctype/fees/fees.py
+++ b/erpnext/education/doctype/fees/fees.py
@@ -82,7 +82,7 @@
def on_cancel(self):
self.ignore_linked_doctypes = ('GL Entry', 'Stock Ledger Entry')
- make_reverse_gl_entries(voucher_type=self.doctype, voucher_no=self.name, cancel=True)
+ make_reverse_gl_entries(voucher_type=self.doctype, voucher_no=self.name)
# frappe.db.set(self, 'status', 'Cancelled')