CRM-21155 - Hook batchItems does not change the csv export
authorErik Hommel <hommel@ee-atwork.nl>
Wed, 6 Sep 2017 10:18:07 +0000 (12:18 +0200)
committerGitHub <noreply@github.com>
Wed, 6 Sep 2017 10:18:07 +0000 (12:18 +0200)
Change to use results of hook when exporting.

CRM/Financial/BAO/ExportFormat/CSV.php

index fcb0d05c349b1aa20f5d3605a6449abc0f24d3c0..1b3513cba1916ecb3ccd10f50c775e1abcd9edd5 100644 (file)
@@ -231,8 +231,8 @@ class CRM_Financial_BAO_ExportFormat_CSV extends CRM_Financial_BAO_ExportFormat
 
       CRM_Utils_Hook::batchItems($queryResults, $batchItems);
 
-      $financialItems['headers'] = self::formatHeaders($financialItems);
-      self::export($financialItems);
+      $batchItems['headers'] = self::formatHeaders($batchItems);
+      self::export($batchItems);
     }
     parent::initiateDownload();
   }