Module: SolidusLegacyPromotions::SpreeShipmentDecorator

Defined in:
app/decorators/solidus_legacy_promotions/models/spree_shipment_decorator.rb

Instance Method Summary collapse

Instance Method Details

#total_before_taxBigDecimal

Returns the amount of this item, taking into consideration all non-tax eligible adjustments.

Returns:

  • (BigDecimal)

    the amount of this item, taking into consideration all non-tax eligible adjustments.



7
8
9
# File 'app/decorators/solidus_legacy_promotions/models/spree_shipment_decorator.rb', line 7

def total_before_tax
  amount + adjustments.select { |adjustment| !adjustment.tax? && adjustment.eligible? }.sum(&:amount)
end