% content_for :title, "Jobs" -%>
Status | Agent / Job | Created | Next Run | Attempts | Last Error | |
---|---|---|---|---|---|---|
<%= status(job) %> | <% case agent = agent_from_job(job) when Agent %><%= link_to(agent.name, agent_path(agent)) %><% when String %><%= agent %><% when false %>(system)<% when nil %>(deleted)<% else %>(unknown)<% end %> | <%= time_ago_in_words job.created_at %> ago<% if user = agent.try(:user) %> for <%= user.username %><% end %> | <% if !job.failed_at %> <%= relative_distance_of_time_in_words job.run_at %> <% end %> | <%= job.attempts %> |
<%= truncate job.last_error, :length => 90, :omission => "", :separator => "\n" %>
" aria-hidden="true">
|
<% if (!job.locked_at && !job.locked_by) || job.failed_at.present? %>
<% if (job.run_at > Time.now) || job.failed_at.present? %>
<%= link_to 'Run now', run_job_path(job), class: "btn btn-default", method: :put %>
<% end %>
<%= link_to 'Delete', job_path(job), class: "btn btn-danger", method: :delete, data: { confirm: 'Really delete this job?' } %>
<% end %>
|