From 7e7e2e3f23afe0cc70bdad588416b324cd0c62b2 Mon Sep 17 00:00:00 2001 From: yashodha Date: Wed, 20 Apr 2016 15:56:48 +0530 Subject: [PATCH] CRM-18438: fix currency for payment info ---------------------------------------- * CRM-18438: Default currency shown in contribution selector https://issues.civicrm.org/jira/browse/CRM-18438 --- CRM/Contribute/BAO/Contribution.php | 3 ++- templates/CRM/Contribute/Form/AdditionalPayment.tpl | 2 +- 2 files changed, 3 insertions(+), 2 deletions(-) diff --git a/CRM/Contribute/BAO/Contribution.php b/CRM/Contribute/BAO/Contribution.php index c39c61d865..f65c46d050 100644 --- a/CRM/Contribute/BAO/Contribution.php +++ b/CRM/Contribute/BAO/Contribution.php @@ -3991,7 +3991,7 @@ WHERE eft.financial_trxn_id IN ({$trxnId}, {$baseTrxnId['financialTrxnId']}) SELECT GROUP_CONCAT(fa.`name`) as financial_account, ft.total_amount, ft.payment_instrument_id, - ft.trxn_date, ft.trxn_id, ft.status_id, ft.check_number + ft.trxn_date, ft.trxn_id, ft.status_id, ft.check_number, con.currency FROM civicrm_contribution con LEFT JOIN civicrm_entity_financial_trxn eft ON (eft.entity_id = con.id AND eft.entity_table = 'civicrm_contribution') @@ -4024,6 +4024,7 @@ WHERE eft.financial_trxn_id IN ({$trxnId}, {$baseTrxnId['financialTrxnId']}) 'receive_date' => $resultDAO->trxn_date, 'trxn_id' => $resultDAO->trxn_id, 'status' => $statuses[$resultDAO->status_id], + 'currency' => $resultDAO->currency, ); if ($paidByName == 'Check') { $val['check_number'] = $resultDAO->check_number; diff --git a/templates/CRM/Contribute/Form/AdditionalPayment.tpl b/templates/CRM/Contribute/Form/AdditionalPayment.tpl index dac87b1e67..3dcb068a05 100644 --- a/templates/CRM/Contribute/Form/AdditionalPayment.tpl +++ b/templates/CRM/Contribute/Form/AdditionalPayment.tpl @@ -36,7 +36,7 @@ {foreach from=$rows item=row} - {$row.total_amount|crmMoney} + {$row.total_amount|crmMoney:$row.currency} {$row.financial_type} {$row.payment_instrument}{if $row.check_number} (#{$row.check_number}){/if} {$row.receive_date|crmDate} -- 2.25.1