Module: SolidusFriendlyPromotions::Conditions::ShipmentLevelCondition

Included in:
ShippingMethod
Defined in:
app/models/concerns/solidus_friendly_promotions/conditions/shipment_level_condition.rb

Instance Method Summary collapse

Instance Method Details

#applicable?(promotable) ⇒ Boolean

Returns:

  • (Boolean)


6
7
8
# File 'app/models/concerns/solidus_friendly_promotions/conditions/shipment_level_condition.rb', line 6

def applicable?(promotable)
  promotable.is_a?(Spree::Shipment)
end

#levelObject



10
11
12
# File 'app/models/concerns/solidus_friendly_promotions/conditions/shipment_level_condition.rb', line 10

def level
  :shipment
end