From f830f6067d9eec42d28b4800a280f0c881793205 Mon Sep 17 00:00:00 2001 From: eileen Date: Thu, 11 Jul 2019 01:02:32 +1200 Subject: [PATCH] Don't pass around paymentTableId --- CRM/Export/BAO/Export.php | 3 +-- CRM/Export/BAO/ExportProcessor.php | 5 +++-- 2 files changed, 4 insertions(+), 4 deletions(-) diff --git a/CRM/Export/BAO/Export.php b/CRM/Export/BAO/Export.php index e08727f327..d8cee057ec 100644 --- a/CRM/Export/BAO/Export.php +++ b/CRM/Export/BAO/Export.php @@ -198,7 +198,6 @@ INSERT INTO {$componentTable} SELECT distinct gc.contact_id FROM civicrm_group_c if ($moreReturnProperties) { $processor->setAdditionalRequestedReturnProperties($moreReturnProperties); } - $paymentTableId = $processor->getPaymentTableID(); list($query, $select, $from, $where, $having) = $processor->runQuery($params, $order); @@ -313,7 +312,7 @@ INSERT INTO {$componentTable} SELECT distinct gc.contact_id FROM civicrm_group_c while ($iterationDAO->fetch()) { $count++; $rowsThisIteration++; - $row = $processor->buildRow($query, $iterationDAO, $outputColumns, $metadata, $paymentDetails, $addPaymentHeader, $paymentTableId); + $row = $processor->buildRow($query, $iterationDAO, $outputColumns, $metadata, $paymentDetails, $addPaymentHeader, $processor); if ($row === FALSE) { continue; } diff --git a/CRM/Export/BAO/ExportProcessor.php b/CRM/Export/BAO/ExportProcessor.php index b714d32e16..f39ae49029 100644 --- a/CRM/Export/BAO/ExportProcessor.php +++ b/CRM/Export/BAO/ExportProcessor.php @@ -797,11 +797,12 @@ class CRM_Export_BAO_ExportProcessor { * @param $metadata * @param $paymentDetails * @param $addPaymentHeader - * @param $paymentTableId + * @param \CRM_Export_BAO_ExportProcessor $processor * * @return array|bool */ - public function buildRow($query, $iterationDAO, $outputColumns, $metadata, $paymentDetails, $addPaymentHeader, $paymentTableId) { + public function buildRow($query, $iterationDAO, $outputColumns, $metadata, $paymentDetails, $addPaymentHeader, $processor) { + $paymentTableId = $processor->getPaymentTableID(); if ($this->isHouseholdToSkip($iterationDAO->contact_id)) { return FALSE; } -- 2.25.1