Class: SolidusFriendlyPromotions::Benefits::AdjustLineItem
Instance Method Summary
collapse
#adjustment_label, #applicable_line_items, #available_calculators, #available_conditions, #compute_amount, #discount, #eligible_by_applicable_conditions?, #preload_relations, #to_partial_path
Instance Method Details
#can_discount?(object) ⇒ Boolean
6
7
8
|
# File 'app/models/solidus_friendly_promotions/benefits/adjust_line_item.rb', line 6
def can_discount?(object)
object.is_a? Spree::LineItem
end
|
#level ⇒ Object
10
11
12
|
# File 'app/models/solidus_friendly_promotions/benefits/adjust_line_item.rb', line 10
def level
:line_item
end
|
#possible_conditions ⇒ Object
14
15
16
|
# File 'app/models/solidus_friendly_promotions/benefits/adjust_line_item.rb', line 14
def possible_conditions
super + SolidusFriendlyPromotions.config.line_item_conditions
end
|