From c5bab3a0fd1fc3bd206a8abb0ee0ced43d87a9b6 Mon Sep 17 00:00:00 2001 From: Eileen McNaughton Date: Wed, 5 Jul 2023 13:39:42 +1200 Subject: [PATCH] Update related contribution trxn_id before sending email This will allow https://github.com/civicrm/civicrm-core/pull/26659 to pass & merge --- CRM/Financial/BAO/Payment.php | 3 +-- 1 file changed, 1 insertion(+), 2 deletions(-) diff --git a/CRM/Financial/BAO/Payment.php b/CRM/Financial/BAO/Payment.php index 97795f7cac..d7e7a5f7c0 100644 --- a/CRM/Financial/BAO/Payment.php +++ b/CRM/Financial/BAO/Payment.php @@ -169,7 +169,7 @@ class CRM_Financial_BAO_Payment { } } } - + self::updateRelatedContribution($params, $params['contribution_id']); if ($isPaymentCompletesContribution) { if ($contributionStatus === 'Pending refund') { // Ideally we could still call completetransaction as non-payment related actions should @@ -213,7 +213,6 @@ class CRM_Financial_BAO_Payment { // change status to refunded. self::updateContributionStatus($contribution['id'], 'Refunded'); } - self::updateRelatedContribution($params, $params['contribution_id']); CRM_Contribute_BAO_Contribution::recordPaymentActivity($params['contribution_id'], CRM_Utils_Array::value('participant_id', $params), $params['total_amount'], $trxn->currency, $trxn->trxn_date); return $trxn; } -- 2.25.1