Commit 42b32794 authored by Monish Deb's avatar Monish Deb

add contribution amount in export query

parent 956e8a96
......@@ -103,7 +103,7 @@ class CRM_Syncintacct_API {
public function createGLBatch($GLBatch) {
$journalEntry = new JournalEntryCreate();
$journalEntry->setJournalSymbol('AR');
$journalEntry->setJournalSymbol('GJ');
$journalEntry->setPostingDate($GLBatch['BATCH_DATE']);
$journalEntry->setDescription($GLBatch['BATCH_TITLE']);
$journalEntry->setAction('Draft');
......
......@@ -35,6 +35,7 @@ class CRM_Syncintacct_Util {
ft.check_number,
c.source AS source,
c.id AS contribution_id,
c.total_amount AS contribution_amount,
c.contact_id AS contact_id,
cc.display_name,
eb.batch_id AS batch_id,
......@@ -71,7 +72,6 @@ class CRM_Syncintacct_Util {
LEFT JOIN civicrm_financial_account fa ON fa.id = fi.financial_account_id
WHERE eb.batch_id = ( %1 )";
$params = array(1 => array($batchID, 'Integer'));
$dao = CRM_Core_DAO::executeQuery($sql, $params);
......@@ -112,6 +112,7 @@ class CRM_Syncintacct_Util {
'DESCRIPTION' => $dao->item_description,
'CLASSID' => $values['class_id'],
'DEPARTMENT' => $values['dept_id'],
'CONTRIBUTION_AMOUNT' => $dao->contribution_amount,
'LOCATION' => $values['location'],
'PROJECTID' => $values['project_id'],
'customfields' => [
......@@ -132,6 +133,7 @@ class CRM_Syncintacct_Util {
'DEPARTMENT' => $values['dept_id'],
'LOCATION' => $values['location'],
'PROJECTID' => $values['project_id'],
'CONTRIBUTION_AMOUNT' => $dao->contribution_amount,
'customfields' => [
'batch_id' => $batchID,
'financial_trxn_id' => $dao->financial_trxn_id,
......
Markdown is supported
0% or
You are about to add 0 people to the discussion. Proceed with caution.
Finish editing this message first!
Please register or to comment