Sha256: bd335ba5b30f2aacf15557cc5687171e39a9353253af51b79622ba40f743e2e3

Contents?: true

Size: 585 Bytes

Versions: 1

Compression:

Stored size: 585 Bytes

Contents

class Plugins::Ecommerce::CartDecorator < Draper::Decorator
  delegate_all
  def the_sub_total
    h.e_parse_price(object.sub_total)
  end

  def the_total_discounts
    h.e_parse_price(object.total_discounts)
  end

  def the_total_amount
    h.e_parse_price(object.total_amount)
  end
  alias_method :the_price, :the_total_amount

  def the_tax_total
    h.e_parse_price(object.tax_total)
  end

  def the_weight_total
    "#{h.current_site.current_weight} #{sprintf('%.2f', object.weight_total)}"
  end

  def the_total_shipping
    h.e_parse_price(object.total_shipping)
  end
end

Version data entries

1 entries across 1 versions & 1 rubygems

Version Path
camaleon_ecommerce-1.2.1 app/decorators/plugins/ecommerce/cart_decorator.rb