Sha256: 1ca6422752602a472eda1abdc9a2d7fddb0e06a4def0150401a2d9c9b496ef14
Contents?: true
Size: 274 Bytes
Versions: 3
Compression:
Stored size: 274 Bytes
Contents
# frozen_string_literal: true module Spree class PromotionAdvertiser def self.for_product(product) promotion_ids = product.promotion_rules.map(&:promotion_id).uniq Spree::Promotion.advertised.where(id: promotion_ids).reject(&:inactive?) end end end
Version data entries
3 entries across 3 versions & 1 rubygems