Method: Resque::JobWithStatus.enqueue
- Defined in:
- lib/resque_ui/overrides/resque_status/job_with_status.rb
.enqueue(klass, options = {}) ⇒ Object
Adds a job of type <tt>klass<tt> to the queue with <tt>options<tt>. Returns the UUID of the job override to pass actual parameters instead of a single hash, to make backward compatible with existing resque jobs.
9 10 11 12 13 |
# File 'lib/resque_ui/overrides/resque_status/job_with_status.rb', line 9 def self.enqueue(klass, = {}) uuid = Resque::Status.create :name => "#{self.name}: #{options.inspect}" Resque.enqueue(klass, uuid, ) uuid end |