From 059c54187551f177be953b67a277cebdefcb13f1 Mon Sep 17 00:00:00 2001 From: Karm Soni Date: Mon, 18 Aug 2025 13:31:47 +0530 Subject: [PATCH] fix: update payment schedule then make gl entries --- erpnext/accounts/doctype/payment_entry/payment_entry.py | 4 ++-- 1 file changed, 2 insertions(+), 2 deletions(-) diff --git a/erpnext/accounts/doctype/payment_entry/payment_entry.py b/erpnext/accounts/doctype/payment_entry/payment_entry.py index e2bd7e82886..07d129c26dd 100644 --- a/erpnext/accounts/doctype/payment_entry/payment_entry.py +++ b/erpnext/accounts/doctype/payment_entry/payment_entry.py @@ -200,9 +200,9 @@ class PaymentEntry(AccountsController): if self.difference_amount: frappe.throw(_("Difference Amount must be zero")) self.update_payment_requests() + self.update_payment_schedule() self.make_gl_entries() self.update_outstanding_amounts() - self.update_payment_schedule() self.set_status() def validate_for_repost(self): @@ -303,10 +303,10 @@ class PaymentEntry(AccountsController): ) super().on_cancel() self.update_payment_requests(cancel=True) + self.update_payment_schedule(cancel=1) self.make_gl_entries(cancel=1) self.update_outstanding_amounts() self.delink_advance_entry_references() - self.update_payment_schedule(cancel=1) self.set_status() def update_payment_requests(self, cancel=False):