Thanks for being a member of the QuickBooks family. I'll gladly help with this. QuickBooks Online comes with a solid sales tax centre that does all the calculations for you. This way, you're ready to file your taxes when the time comes.
When you offer a product at a discount to a customer, the discount does not affect the sales tax calculations. The taxes shown in the transaction are based on the sub-total amount of the transaction after the discount is taken in consideration.