I am trying to create an order with an ORDER scope discount but running into order total mismatch.
Lets say this is the order I created:
- Pizza : $12 [15% tax applies on it]
- Drink : $1 [NO tax applies]
Items Total: $13
Order Total: $13.65
Now when I send this order to Square, in the response what I get back is that the $1 discount applies to both the line items (Pizza and Drink). Pizza has discount of 92 cents and Drink has 8 cents.
Item Total: $12.74
Order Total In Response: $13.66
Which is 1 cent higher than it suppose to be which result in mismatch when we add the payment to this order with correct amount of $13.65
Issue is that the discount is being applied on all line items which mess up the line item tax amount and eventually the line item total.
Total mismatch grows more when we have more items in cart and more discounts.