This helper is used when making changes to an Order, to apply all applicable price adjustments to that Order, including:
(ctx: RequestContext, order: Order, promotions: Promotion[], updatedOrderLines: OrderLine[] = [], options?: { recalculateShipping?: boolean }) => Promise<Order>Applies taxes and promotions to an Order. Mutates the order object. Returns an array of any OrderItems which had new adjustments applied, either tax or promotions.
(order: Order) => Sets the totals properties on an Order by summing each OrderLine, and taking into account any Surcharges and ShippingLines. Does not save the Order, so the entity must be persisted to the DB after calling this method.
Note that this method does not evaluate any taxes or promotions. It assumes that has already been done and is solely responsible for summing the totals.