From 9f988910b54a3ca0cf00d1706127f4ad5e349e1c Mon Sep 17 00:00:00 2001 From: Maharshi Patel Date: Sun, 25 Sep 2022 23:24:59 +0530 Subject: [PATCH] fix: payment reconciliation tool consider cost_center for JV We need to consider cost center in all four cases of get_conditions. I have removed check in if statement for get_invoices, get_payments, get_return_invoices as it is not required. --- .../doctype/payment_reconciliation/payment_reconciliation.py | 2 +- 1 file changed, 1 insertion(+), 1 deletion(-) diff --git a/erpnext/accounts/doctype/payment_reconciliation/payment_reconciliation.py b/erpnext/accounts/doctype/payment_reconciliation/payment_reconciliation.py index e5b942fb6ef..9b81657af52 100644 --- a/erpnext/accounts/doctype/payment_reconciliation/payment_reconciliation.py +++ b/erpnext/accounts/doctype/payment_reconciliation/payment_reconciliation.py @@ -332,7 +332,7 @@ class PaymentReconciliation(Document): def get_conditions(self, get_invoices=False, get_payments=False, get_return_invoices=False): condition = " and company = '{0}' ".format(self.company) - if self.get("cost_center") and (get_invoices or get_payments or get_return_invoices): + if self.get("cost_center"): condition = " and cost_center = '{0}' ".format(self.cost_center) if get_invoices: