Sha256: adfa3f5d741c7747949738d028412e76fc4aea746a51743ece60d06cc6532643

Contents?: true

Size: 1.03 KB

Versions: 2

Compression:

Stored size: 1.03 KB

Contents

<% size = Resque.redis.llen(Resque::Plugins::History::HISTORY_SET_NAME) %>
<% start = params[:start].to_i %>
<% history = Resque.redis.lrange(Resque::Plugins::History::HISTORY_SET_NAME, start, start + 20)%>

<h1 class='wi'>Job history</h1>

<% if size > 0 %>
  <form method="POST" action="<%=u 'history/clear'%>" class='clear-delayed'>
    <input type='submit' name='' value='Clear History' />
  </form>
<% end %>

<p class='intro'>Showing <%=start%> to <%= start + 20 %> of <b><%= size = Resque.redis.llen(Resque::Plugins::History::HISTORY_SET_NAME) %></b> jobs</p>

<%= partial :next_more, :start => params[:start].to_i, :size => size %>

<table class='queues1'>
  <tr>
    <th>Job</th>
    <th>Arguments</th>
    <th>Time</th>
  </tr>
  <% history.each do |history| %>
      <% j = JSON.parse(history) %>
      <tr>
        <td class='queue'><%= j["class"] %></td>
        <td class='args'><%= j["args"] %></td>
        <td class='args'><%= j["time"] %></td>
      </tr>
  <% end %>
</table>

<%= partial :next_more, :start => start, :size => size %>

Version data entries

2 entries across 2 versions & 1 rubygems

Version Path
resque-history-1.7.1 lib/resque-history/server/views/history.erb
resque-history-1.7.0 lib/resque-history/server/views/history.erb