Skip to content

Add support to account id, payment type etc. #62

New issue

Have a question about this project? Sign up for a free GitHub account to open an issue and contact its maintainers and the community.

By clicking “Sign up for GitHub”, you agree to our terms of service and privacy statement. We’ll occasionally send you account related emails.

Already on GitHub? Sign in to your account

Open
wants to merge 1 commit into
base: master
Choose a base branch
from

Conversation

sunilpawar
Copy link

Additional changes:

  • Avoid syncing negative total amounts. (QB does not accept itself)
  • Avoid syncing line items if qty = 0
  • Pass payment method.
  • Pass DepositToAccountRef
  • Pass trxn_id or check_number as PaymentRefNum

@sunilpawar
Copy link
Author

@agileware-justin , @agileware-fj

Can you please take a look?

@agileware-justin
Copy link
Contributor

@sunilpawar we have had a look, thanks.

@agileware-fj agileware-fj self-assigned this May 7, 2025
Copy link
Contributor

@agileware-fj agileware-fj left a comment

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Please respond to these questions @sunilpawar

// finished before you did, so your work was not saved.
$invoiceExiting = $this->getInvoiceFromQBO($record);
$accountsInvoice->SyncToken = $invoiceExiting->SyncToken;

Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

Have always been a little apprehensive about doing this in the push function, however on balance of things I guess if an important change had been made, it would have been pulled in during the InvoicePull call already anyway.
Approved

'name' => "quickbooks_account_id",
'group' => 'civiquickbooks',
]);
$paymentInstrument = CRM_Contribute_BAO_Contribution::buildOptions('payment_instrument_id', 'create');
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

I think buildOptions is deprecated, this could be an API call?

}
}

// set Account ID
Copy link
Contributor

Choose a reason for hiding this comment

The reason will be displayed to describe this comment to others. Learn more.

My understanding is that on the Quickbooks side, each product or service should have an Income account set, and we should defer where the payments go to this.

Is there a particular reason for having a setting for one particular income account that overrides this behaviour? It doesn't sound like the correct approach

Sign up for free to join this conversation on GitHub. Already have an account? Sign in to comment
Labels
None yet
Development

Successfully merging this pull request may close these issues.

3 participants