Open Noah-Silvera opened 2 years ago
One question that still remains in this ticket is how do we determine that someone isn't already handling order level adjustments? Maybe comparing the new line item totals to the order amount and seeing if they don't match? Because that is the underlying problem which causes the TaxJar API to return an error.
Taken from #178
As discussed in #178, this scenario is handled by allowing users to configure a custom
discount_calculator
which will let them determine how to handle splitting the discount among items for order level adjustments if desired.However, as discovered in the testing of #139, order level adjustments will cause the creation of the "refund+new transaction" to fail silently and put your TaxJar reporting into a bad state (the order has been fully refunded, but a new transaction has not been created with the reduced amount)
To prevent this from happening, we should do the following.
discount_calculator
option d.) We should display a link to the documentation so they can learn how to handle order level adjustments if desired.