Class: Spree::Products::RefreshMetricsJob
- Defined in:
- app/jobs/spree/products/refresh_metrics_job.rb
Instance Method Summary collapse
Instance Method Details
#perform(product_id, store_id) ⇒ Object
6 7 8 9 10 11 |
# File 'app/jobs/spree/products/refresh_metrics_job.rb', line 6 def perform(product_id, store_id) store_product = Spree::StoreProduct.find_by(product_id: product_id, store_id: store_id) return unless store_product store_product.refresh_metrics! end |