Sha256: cf04faef266e3dac8a67e22218a5e9849cd600a10996f0ab3cf5af40f575be2f
Contents?: true
Size: 238 Bytes
Versions: 8
Compression:
Stored size: 238 Bytes
Contents
class Calculator::PerItem < Calculator preference :amount, :decimal, :default => 0 def self.description I18n.t("flat_rate_per_item") end def compute(object=nil) self.preferred_amount * object.line_items.length end end
Version data entries
8 entries across 8 versions & 1 rubygems