Sha256: 6ae1a7ce79cead2f8ad2732028fcd108400ac86c622cd01af9247f0d3315a45a
Contents?: true
Size: 545 Bytes
Versions: 4
Compression:
Stored size: 545 Bytes
Contents
require "active_job" module DelayedPaperclip class ProcessJob < ActiveJob::Base def self.enqueue_delayed_paperclip(instance_klass, instance_id, attachment_name) queue_name = instance_klass.constantize.paperclip_definitions[attachment_name][:delayed][:queue] set(:queue => queue_name).perform_later(instance_klass, instance_id, attachment_name.to_s) end def perform(instance_klass, instance_id, attachment_name) DelayedPaperclip.process_job(instance_klass, instance_id, attachment_name.to_sym) end end end
Version data entries
4 entries across 4 versions & 2 rubygems