From a5dfe0725fd48b8d25ab27ef65c19fa7b98a7bc2 Mon Sep 17 00:00:00 2001 From: Nabin Hait Date: Thu, 12 Sep 2019 19:17:24 +0530 Subject: [PATCH] fix: payment against shareholder (#19019) --- erpnext/accounts/doctype/payment_entry/payment_entry.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/erpnext/accounts/doctype/payment_entry/payment_entry.py b/erpnext/accounts/doctype/payment_entry/payment_entry.py index 536a6ed2c5..3529900d56 100644 --- a/erpnext/accounts/doctype/payment_entry/payment_entry.py +++ b/erpnext/accounts/doctype/payment_entry/payment_entry.py @@ -126,7 +126,7 @@ class PaymentEntry(AccountsController): if not self.party: frappe.throw(_("Party is mandatory")) - _party_name = "title" if self.party_type == "Student" else self.party_type.lower() + "_name" + _party_name = "title" if self.party_type in ("Student", "Shareholder") else self.party_type.lower() + "_name" self.party_name = frappe.db.get_value(self.party_type, self.party, _party_name) if self.party: