% if j[:success] %>
<%= if defined? title then title else 'success' end %>
<% elsif j[:success] == false %>
<%= if defined? title then title else 'failed' end %>
<% elsif j[:finished_at] %>
<%= if defined? title then title else 'finished' end %>
<% elsif j[:started_at] %>
<%= if defined? title then title else 'running' end %>
<% elsif not j.nil? %>
<%= if defined? title then title else 'queued' end %>
<% else %>
<%= if defined? title then title else 'not ready' end %>
<% end %>