Module: Barbeque::JobExecutionsHelper
- Defined in:
- app/helpers/barbeque/job_executions_helper.rb
Instance Method Summary collapse
Instance Method Details
#status_label(status) ⇒ Object
2 3 4 5 6 7 8 9 10 11 12 13 14 15 16 17 18 19 20 21 |
# File 'app/helpers/barbeque/job_executions_helper.rb', line 2 def status_label(status) color = case status when 'success' 'success' when 'failed' 'danger' when 'retried' 'warning' when 'pending' 'info' when 'error' 'danger' when 'running' 'info' else 'default' end content_tag(:span, status.upcase, class: "label label-#{color}") end |