You signed in with another tab or window. Reload to refresh your session.You signed out in another tab or window. Reload to refresh your session.You switched accounts on another tab or window. Reload to refresh your session.Dismiss alert
We've seen several reports of these errors in invoice logs. The case to get this error is slightly complicated. I think the below steps should be able to replicate -
Create a contribution in civicrm with status = Pending. This inserts a row in account_invoice table with needs_update = 1 and account_status_id` = 2
Push this contribution to xero. needs_update is set to 0.
Update the invoice on xero account. Mark them as Paid.
In civi, when the "Pull" job is executed, it updates the value of account_status_id to 1. All correct till now.
Next, when CiviAccountSync Complete Contributions job is executed, it updates the status of the contribution to 1 (completed). This also modifies the needs_update flag in civicrm_account_invoice table.
Again, when the push job is executed with an intention to update the status of invoice on xero, it notices that the status is already updated (in step 3) and records the below error in error_log field.
Invoice not of valid status for modification This document cannot be edited as it has a payment or credit note allocated to it.
We had ~480 rows displayed with the same error message. Workaround is to avoid updating the status of the invoice in "Xero" and instead use civicrm to update the contribution which correctly updates the invoice when "Push" job is executed.
@eileenmcnaughton Thoughts? Probably, we should not set "needs_update" in step 5, but hard to identify if account_status_id was set to 1 from the pull job or via some ipn notification? OR
While push job, simply bypass this error if status on xero matches with existing status in civicrm?
The text was updated successfully, but these errors were encountered:
We've seen several reports of these errors in invoice logs. The case to get this error is slightly complicated. I think the below steps should be able to replicate -
Create a contribution in civicrm with status = Pending. This inserts a row in
account_invoice
table withneeds_update
= 1 and account_status_id` = 2Push this contribution to xero.
needs_update
is set to 0.Update the invoice on xero account. Mark them as
Paid
.In civi, when the "Pull" job is executed, it updates the value of
account_status_id
to 1. All correct till now.Next, when
CiviAccountSync Complete Contributions
job is executed, it updates the status of the contribution to 1 (completed). This also modifies theneeds_update
flag incivicrm_account_invoice
table.Again, when the push job is executed with an intention to update the status of invoice on xero, it notices that the status is already updated (in step 3) and records the below error in error_log field.
We had ~480 rows displayed with the same error message. Workaround is to avoid updating the status of the invoice in "Xero" and instead use civicrm to update the contribution which correctly updates the invoice when "Push" job is executed.
@eileenmcnaughton Thoughts? Probably, we should not set "needs_update" in step 5, but hard to identify if
account_status_id
was set to 1 from the pull job or via some ipn notification? ORWhile push job, simply bypass this error if status on xero matches with existing status in civicrm?
The text was updated successfully, but these errors were encountered: