Sha256: da6683f4605c40617bd9609cb489fd04cd4e2511c2fffbc4a1ea039a9d7fa8ef
Contents?: true
Size: 653 Bytes
Versions: 13
Compression:
Stored size: 653 Bytes
Contents
module TasksHelper def icon_for_task task icon = 'icon_warning.gif' alt = 'Unknwon' if task.pending? icon = 'icon_pending.gif' alt = 'Pending' elsif task.init_queue? icon = 'icon_init_queue.gif' alt = 'Initialize Queue' elsif task.acquire_lock? icon = 'icon_acquire_lock.png' alt = 'Acquire Lock' elsif task.running? icon = 'icon_running.gif' alt = 'Running' elsif task.successful? icon = 'icon_successful.png' alt = 'Successful' elsif task.error? icon = 'icon_error.png' alt = 'Error!' end image_tag(icon, :alt => alt) end end
Version data entries
13 entries across 13 versions & 1 rubygems