Module: Spree::Admin::PromotionActionsHelper

Defined in:
app/helpers/spree/admin/promotion_actions_helper.rb

Instance Method Summary collapse

Instance Method Details

#options_for_promotion_action_types(promotion) ⇒ Object



4
5
6
7
# File 'app/helpers/spree/admin/promotion_actions_helper.rb', line 4

def options_for_promotion_action_types(promotion)
  existing = promotion.actions.pluck(:type)
  Spree.promotions.actions.map(&:name).reject { |r| existing.include? r }
end