Problem/motivation

While working with adjustments, and specifically tax adjustments, I realize we need the ability to get an order item's adjusted price, not just the total (unit price * qty). For example, if there are order item adjustments, the unit price will be recorded with qty as the order item total, but the adjusted price will take those order item adjustments into account. Tax calculation, in this case, is concerned with the adjusted price. The order will apply those adjustments in their own adjustment item on the order, but the tax service needs the adjusted price.

Proposed resolution

Add getTotalAdjustedPrice to OrderItemInterface
Implement getTotalAdjustedPrice as order item total price + adjustments

Comments

steveoliver created an issue. See original summary.

steveoliver’s picture

Question: do we also save the adjusted price as a field, or leave it as a runtime getter only?

steveoliver’s picture

Status: Active » Needs review
finne’s picture

See my comment on github

  • bojanz committed 5fcec50 on 8.x-2.x authored by steveoliver
    Issue #2842256 by steveoliver, finne: Provide a getter method for...

bojanz credited bojanz.

bojanz’s picture

Status: Needs review » Fixed

Finally :)

Status: Fixed » Closed (fixed)

Automatically closed - issue fixed for 2 weeks with no activity.