1
0
Fork 0
mirror of https://github.com/mperham/sidekiq.git synced 2022-11-09 13:52:34 -05:00

Polish worker arguments display, fixes #1453

This commit is contained in:
Mike Perham 2014-01-27 20:26:51 -08:00
parent dbabcb8c84
commit f58b6926b8

View file

@ -12,16 +12,9 @@
<td>
<a href="<%= root_path %>queues/<%= msg['queue'] %>"><%= msg['queue'] %></a>
</td>
<td><%= msg['payload']['class'] %></td>
<td>
<% if msg['payload']['args'].to_s.size > 100 %>
<%= h(msg['payload']['args'].inspect[0..100]) + "... " %>
<button data-toggle="collapse" data-target="#worker_<%= index %>" class="btn btn-default btn-xs"><%= t('ShowAll') %></button>
<div class="toggle" id="worker_<%= index %>" style="display: none;max-width: 750px;"><%= h(msg['payload']['args']) %></div>
<% else %>
<%= h(msg['payload']['args']) %>
<% end %>
<div class="args"><%= display_args(msg['payload']['args']) %></div>
</td>
<td><%= relative_time(msg['run_at'].is_a?(Numeric) ? Time.at(msg['run_at']) : Time.parse(msg['run_at'])) %></td>
</tr>