- Add initializer to
config/application.rb - Add new class to
app/models/spree/calculators/[class_name].rb - Add logic to class file
Class must have the following methods:
def self.description
"Custom FlexiRate"
end
def compute(line_items)
13.00
end
Instead of this path:
It should be this path:
Notice
calculators(plural) ->calculator(singular).